NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io, #1295 most downloaded on crates.io
A git-config file parser and editor from the gitoxide project
Latest stable
0.62.2
Last release 29 days ago
24 Oct 2026
Ships on a steady schedule
a new release about every 4 weeks
Nearly every release is documented
notes for 59 of 59 stable releases
1 version withdrawn
withdrawn after publishing
4 years old
60 releases · first in 2023
3 commits contributed to the release over the course of 16 calendar days.
Your coding agent can read these notes before it upgrades. Set up the MCP server →
<csr-id-69ec5940d3f37eb4dace8f1ed7616b5988984d15/> <csr-id-9cd99337333f5ef4b30e0ec9461fc087699576e6/> <csr-id-0076dcf9b37f1d633bdad5573b40d34a9fbaba90/> <csr-id-a8604a237782f8d60a185d4730db57bad81424a6/> <csr-id-55c00d880535a1f8c37cb7d4405d39ff5a7654a0/> <csr-id-32d5b3c695d868ba93755123a25b276bfbe55e0a/> <csr-id-949622e461eb2116393ec6f4633ec0cb2e1695b5/> <csr-id-bcacfc9bcf19a0339541b24e84de68d95291c62b/> <csr-id-41f118d2aa560188fd3399d2390aa43794b0af75/> <csr-id-f7f136dbe4f86e7dee1d54835c420ec07c96cd78/>
A maintenance release without user-facing changes.
<csr-id-0c98ec8fc7d8cc3195472a04fde4a681f620725f/> subsections are identified as &BStr in entire API.
Technically they can be any value (except for newlines and unescaped double quotes),
and these values might be paths and everything that comes with it, like
illformed UTF8. In order to be able to represent everything that
git can represent, we don't enforce UTF8 anymore for subsection names.
Note that section names and key names are required to be valid UTF8 (and even alphanumeric ascii), which makes illformed UTF8 very unlikely there.
<csr-id-a93a156655d640ae63ff7c35b0a1f5d67a5ca20f/> Simplify specifying keys when mutating config values.
<csr-id-895ce40aabbe6d6af5b681a0d0942303fd6549a2/> File::rename_section() with validation of input arguments.
<csr-id-4a01d983f54a7713dea523f6032cbf5bb2b9dde8/> improve normalization; assure no extra copies are made on query.
We now return our own content, rather than the originals with their
lifetimes, meaning we bind lifetimes of returned values to our own
File instance. This allows them to be referenced more often, and
smarter normalization assures we don't copy in the simple cases
either.
More tests were added as well.
This is breaking as lifetime changes can cause distruptions, and
values?_as() was removed as well as it's somewhat duplicate
to higher-level APIs and it wasn't tested at all.
<csr-id-c9933c0b0f51d21dc8244b2acc33d7dc8a33f6ce/> Remove git-config test utilities from git-path.
<csr-id-2faad43d11283ff06381c51d2466307cfb8736ff/> transfer knowledge about configuration and its usage into the type system. That way it's possible to use configuration overrides, even though ultimately being strings, in a type-safe manner and leverage code-completion while at it.
In that process, we also change Repository::(committer|Author)() to return
Option<Result<...>> to be able to account for date parse errors.
<csr-id-2b36d99eaf3ed24ce4cb736a3dd48440dc0c73b7/> File::new_section() and related now returns their id as well.
That way it's possible to more easily interact with it later, for instance
when one wants to delete it.
<csr-id-3d8fa8fef9800b1576beab8a5bc39b821157a5ed/> upgrade edition to 2021 in most crates. MSRV for this is 1.56, and we are now at 1.60 so should be compatible. This isn't more than a patch release as it should break nobody who is adhering to the MSRV, but let's be careful and mark it breaking.
Note that git-features and git-pack are still on edition 2018
as they make use of a workaround to support (safe) mutable access
to non-overlapping entries in a slice which doesn't work anymore
in edition 2021.
<csr-id-b6cd6ace412b0c0df4bacbe7ed7ef6608f27909c/> file::SectionMut::push() now supports values without key-value separator.
These make a difference as those without = are considered boolean
true.
Currently pushing onto a section is the only way to write them.
<csr-id-d003c0f139d61e3bd998a0283a9c7af25a60db02/> Support for lossy load mode.
There is a lot of breaking changes as file::from_paths::Options now
became file::init::Options, and the same goes for the error type.
<csr-id-1ea26d80f392114349d25ebf88a7b260ee822aa1/> add _filter() versions to most access methods.
That way it's possible to filter values by their origin.
Note that the remove_section() methods now return the entire
removed section, not just the body, which yields more information
than before including section metadata.
<csr-id-cfd974f46d2cbb99e7784a05f5e358fed0d4bcab/> section names are now validated.
<csr-id-6ba2f8060768978ad7204e162fb2253ca8843879/> filtering supportort for parse::Events.
That way it's possible to construct Files which are not destined to be
written back as they only keep events necessary for value access,
greatly reducing allocations.
<csr-id-311d4b447daf8d4364670382a20901468748d34d/> change mostily internal uses of [u8] to BString/BStr
<csr-id-edd226719cd04a480274cb7d983b6d5d8bfdbb13/> Path-interpolation makes home-dir configurable.
That way the caller has full control over how the environment is used,
which also allows more fine-grained control over which config files
can be included.
<csr-id-266d4379e9132fd7dd21e6c8fccb36e125069d6e/> Make realpath() easier to use by introducing realpath_opt().
That way there is consistency about how many symlinks to follow.
<csr-id-27fb1ce27d2985eb1ee8bee5fffaf759902571fb/> Add Kind::GitInstallation for a way to obtain special git-installation configuration paths.
Note that these are lazily cached as they call the git binary.
<csr-id-99905bacace8aed42b16d43f0f04cae996cb971c/> upgrade bstr to 1.0.1
<csr-id-2b2357e9cc54539e0dbe7c0e22802f2b884160d8/> Add File::set_raw_value() to unconditionally set single values, and make the value itself easier to provide.
<csr-id-17c83d55f8942788aac5eb1bea22a48daa045bf4/> add File::resolve_includes() and move its error type to file::includes.
<csr-id-5221676e28f2b6cc1a7ef1bdd5654b880965f38c/> add File::from_bytes_owned() and remove File::from_path_with_buf()
<csr-id-98d45c2f59863fdee033b38e757cec09593f6892/> remove File::from_env_paths().
It's replaced by its more comfortable new_globals().
<csr-id-230a523593afcfb8720db965ff56265aaceea772/> untangle file::init::… Option and Error types.
This moves types to where they belong which is more specific instead
of having a catch-all Error and Options type.
<csr-id-3f3ff11a6ebe9775ee5ae7fc0ec18a94b5b46d61/> rename parse::Comment::(comment_tag|comment) to ::tag|text and parse::Section::section_header to ::header.
<csr-id-6f4eea936d64fb9827277c160f989168e7b1dba2/> Associate file::Metadata with each File.
This is the first step towards knowing more about the source of each
value to filter them based on some properties.
This breaks various methods handling the instantiation of configuration
files as file::Metadata typically has to be provided by the caller
now or be associated with each path to read configuration from.
<csr-id-b672ed7667a334be3d45c59f4727f12797b340da/> rename file::SectionBody to file::section::Body.
<csr-id-3bea26d7d2a9b5751c6c15e1fa9a924b67e0159e/> Remove File::sections_by_name_with_header() as ::sections_by_name() now returns entire sections.
<csr-id-41b3e622ee71943c285eadc518150fc7b6c92361/> create resolve_includes options to make space for more options when loading paths.
<csr-id-cabc8ef0e31c954642525e7693009a7fe4b4c465/> rename path::Options into path::Context.
It's not an option if it's required context to perform a certain
operation.
<csr-id-3de0cfd81523e4ba7cc362d8625f85ebf8fd9172/> All accessors in File are now using impl AsRef<str> where possible for added comfort.
<csr-id-3d25fe6c7a52529488fab19c927d64a1bc75838f/> Much more comfortable API file::*Mut types thanks to impl Into/AsRef.
<csr-id-393b392d515661e5c3e60629319fdab771c3d3f0/> Rename Mutable* into $1Mut for consistency.
<csr-id-0a7391a6575f4035c51a46d34fa20c69e9d078e9/> conform APIs of file::MutableValue and file::MutableMultiValue.
There are more renames and removals than worth mentioning here given the
current adoption of the crate.
<csr-id-83a0922f06081312b79908835dac2b7f4e849bb3/> rename file::MutableSection::set_leading_space() to set_leading_whitespace().
The corresponding getter was renamed as well to leading_whitespace().
<csr-id-219cf7ae0b35b3ac92f97974be52cd022698e01f/> Enforce parse::section::Header::new() by making its fields private.
<csr-id-4f6cd8cf65c2d8698bffe327a19031c342b229a6/> Add File::write_to() and File::to_bstring(); remove some TryFrom impls.
Now File can be serialized in a streaming fashion and without the
possibility for UTF8 conversion issues.
Note that Display is still imlpemented with the usual caveats.
<csr-id-0e392f81e99c8c0ff29f41b9b86afd57cd99c245/> remove Integer::to_bstring() as well as some TryFrom impls.
Note that it can still display itself like before via
std::fmt::Display.
<csr-id-b22732a2ab17213c4a1020859ec41f25ccabfbfc/> remove Boolean::to_bstring() along with a few From impls.
These were superfluous and aren't useful in practice.
Note that serialization is still implemented via Display.
<csr-id-65c520c4de8187884f87059adf5cef9cbdcd90a2/> allocation free File::sections_by_name() and File::sections_by_name_with_header().
<csr-id-ac57c4479e7b6867e8b8e71f7cf76de759dc64a2/> Path::interpolate() now takes path::interpolate::Options instead of three parameters.
<csr-id-0915051798dd782b40617a1aa16abd71f6db1175/> remove String type in favor of referring to the File::string() method.
The wrapper had no effect whatsoever except for adding complexity.
<csr-id-9cadc6f0cbaad0ac23f5469db2f040aecfbfb82c/> Simplify Boolean to be a wrapper around bool.
Previously it tried hard not to degenerate information, making it a
complicated type.
However, in practice nobody cares about the exact makeup of the boolean, and there is no need to serialize a boolean faithfully either.
Instead, those who want to set a value just set any value as a string, no need for type safety there, and we take care of escaping values properly on write.
<csr-id-703922dd4e1e5b27835298217ff4eb8ef1dc57ce/> Use bitflags for color::Attribute instead of Vec of enums.
This is less wasteful and sufficient for git, so it should be sufficient
for us, especially since attributes are indeed a set and declaring
one twice has no effect.
<csr-id-3fc4ac04f46f869c6e3a94ce4bb8a5737aa0c524/> simplify Color API.
For now we only parse and serialize for display, but more uses are
enabled when needed and trivially.
<csr-id-14149eea54e2e8a25ac0ccdb2f6efe624f6eaa22/> remove parse::Events::from_path and File::at
The latter has been replaced with File::from_path_with_buf(…) and
is a low-level way to load just a single config file, purposefully
uncomfortable as it will not resolve includes.
The initialization API will need some time to stabilize.
<csr-id-73adceeae12270c0d470d4b7271c1fd6089d5c2d/> Slim down API surface of parse::Events.
It's more of a 'dumb' structure now than before, merely present
to facilitate typical parsing than something special on its own.
<csr-id-2e47167e4a963743494b2df6b0c15800cb876dd0/> remove File::new() method in favor of File::default().
<csr-id-ea6765093b5475912ba1aa81d4440cbf5dd49fb6/> rename parse::event::List to parse::Events
<csr-id-89f5fca843d999c5bea35fb3fe2a03dc3588f74e/> rename parse::State to parse::event::List
<csr-id-3cdb0890b71e62cfa92b1ed1760c88cb547ec729/> move value::* into the crate root, except for Error and normalize_*().
<csr-id-748d921efd7469d5c19e40ddcb9099e2462e3bbc/> rename value::parse::Error to value::Error.
<csr-id-7e8a22590297f2f4aab76b53be512353637fb651/> rename value::TrueVariant to value::boolean::True
<csr-id-8bcaec0599cf085a73b344f4f53fc023f6e31430/> rename IntegerSuffix to integer::Suffix
<csr-id-d085037ad9c067af7ce3ba3ab6e5d5ddb45b4057/> rename value::Color(Attribute|Value) to value::color::Attribute and value::color::Name.
<csr-id-a0f6252343a62b0b55eef02888ac00c09100687a/> Turn parse::ParseOrIoError into parse::state::from_path::Error
<csr-id-b6b31e9c8dd8b3dc4860431069bb1cf5eacd1702/> rename parse::ParsedComment into parse::Comment
<csr-id-239cbfb450a8cddfc5bec1de21f3dc54fab914ce/> rename parse::Section* related types.
These are now located in section::*.
<csr-id-60af4c9ecb1b99f21df0e8facc33e5f6fc70c424/> rename parse::Parser to parse::State.
Furthermore, make State the entry point for all parsing, removing
all free-standing functions that returned a State.
<csr-id-3724850e0411f1f76e52c6c767fd8cebe8aea0f6/> rename parser module to parse
<csr-id-58b22152a0295998935abb43563e9096589ef53e/> rename normalize_cow() to normalize() and move all normalize* functions from values to the value module
<csr-id-767bedccdae1f3e6faf853d59ecf884a06cc3827/> move Path from values to value module
<csr-id-6033f3f93d2356399a661567353a83a044662699/> Move Boolean and String from values into value module
<csr-id-d4444e18042891b0fe5b9c6e6813fed26df6c560/> move values::Integer into value module
<csr-id-38f31174e8c117af675cdfbc21926133b821ec38/> move Color to own value module
<csr-id-aa630ad6ec2c6306d3307d5c77e272cb24b00ddd/> remove values::Bytes - use values::String instead.
Note that these values are always normalized and it's only possible
to get a raw values using the raw_value() API.
<csr-id-553f87225363903e6acdb3e7eaa8cc66a91110f1/> File::len() -> File::num_values()
The same is true for Section::len() which now is
Section::num_values().
<csr-id-c7fcb5e1db225aefc3eeab4f29f3fb85c670894a/> GitConfig::from_paths(…, <option>) is now owned.
The type is Copy, so no need to pass it by reference.
<csr-id-38dfdcf80f9b7368ccaa10f4b78b2129849848d0/> remove values::*Error in favor of value::parse::Error.
This makes it easier to work with errors in practice, we are either
interested in the value that failed to parse to try something else
or want a nice user message.
Having one decode error type facilitates that.
<csr-id-a98a7a7af69482e9ef63f106184049049939459d/> switch from quickerror to thiserror. This allows for generic types for sources of errors and allows to workaround a limitation with associated type constraints in the MSRV of 1.54.
Using thiserror makes this work and brings the crate more closely to the rest of the gitoxide crates (which now prefer thiserror over quickerror).
<csr-id-a86b2541561674df5dbef4120d3e03483cb80117/> remove all get_ prefixes from methods
That way the API is more idiomatic and fits better into the
existing gitoxide crates.
<csr-id-f9aaac11f0734afbd791132369eb5601bfc7efe9/> use lookup::Error and lookup::existing::Error
Use the newly introduced structured error to replace the 'catch-all'
GitConfigError while getting closer to naming conventions in other
gitoxide crates.
<csr-id-8836f5ada0078febf8aeb0e6b59d0fc4c588bc28/> File::section(...) could panic due to invlid expectation.
This has been fixed to prevent panics.
<csr-id-839f776454d7a8522c0f2887c90fc41b20576bd9/> File::boolean() now correctly handles implicit bools across sections.
This means it will return the last implicit value as true, instead of
ignoring it to fall back onto an explicit boolean value that might be
false.
<csr-id-7d92c61abc2c54f4a64c35b37bcd1843a8d1da9c/> file::SectionMut::push() now properly creates empty values.
Previously, when calling .push("key", None), the resulting internal
state would be slighly wrong causing certain invariants and expectations
to be unfulfilled even though it might have looked OK to most users.
Now it will uphold the invariant for empty values, those without an
= character.
<csr-id-9c1e639979a9615fd8334ce0e3a809df137776f6/> greatly improve whitespace handling when removing values. Previously, newlines would remain past a value, and whitespace could remain before one.
Now both are removed to simulate removing an actual line.
<csr-id-e533993e8f861ba7a6600aab114ddfecc8a85ee2/> File::remove_section() was fixed to allow re-adding a similarly named section.
We also add File::remove_section_by_id() to make it possible to remove
specific sections.
<csr-id-08c50a47fa901457194539c7db74ad47ab2f8b60/> Properly handle boolean values such that a is true but a= is false.
This is even consistent when no booleans are used, such that a has no
value as if it is not present, it's only available for booleans which
must be specified.
<csr-id-7c585162454c476fe93f032c8a2329cffd7c054f/> Keep track of a severe limitation and prepare tests for fixing it.
This also changes behaviour, but merely removes a hack in Boolean
which considered empty strings true, even though they are supposed to be
false.
<csr-id-6c1588fd1a2fa80fd866787cbf4bcc6e5b51abe6/> maintain insertion order of includes on per-section basis at least. Note that git inserts values right after the include directive, 'splitting' the section, but we don't do that and insert new values after the section. Probably no issue in practice while keeping our implementation simple.
<csr-id-f7bd2caceb87a179288030e0771da2e4ed6bd1e4/> maintain newline format depending on what's present or use platform default.
Previously implicit newlines when adding new sections or keys to
sections was always \n which isn't correct on windows.
Now the newline style is detected and used according to what's present, or in the lack of content, defaults to what's correct for the platform.
<csr-id-0d07ef1aa4a9e238c20249d4ae2ed19e6740308a/> validate incoming conifguration keys when interpreting envirnoment variables.
<csr-id-6b901843cb18b3d31f8b0b84bb9ebbae279aff19/> Boolean can use numbers to indicate true or false, drops support for one and zero.
<csr-id-94dde44e8dd1a0b8d4e11f2627a3f6b345a15989/> file::MutableSection::remove() now actually removes keys and values.
<csr-id-048b92531eb877a5a128e702504891bf1e31becf/> file::MutableMultiValue escapes input values and maintains key separator specific whitespace.
<csr-id-f911707b455ba6f3800b85f667f91e4d56027b91/> value normalization (via value::normalize() handles escape sequences.
The latter ones are \n, \t and \b which are the only supported
ones in values of git-config files.
<csr-id-44dfec07480cc2ac6fd01674b748cc03af51fed1/> stable sort order for File::sections_by_name_with_header()
<csr-id-1ea919d5ff81ab7b01b8201386ef63c7e081b537/> count newlines (for error display) in multi-line values as well
<csr-id-1e71e71c984289f0d7e0a39379ee6728918b7dc5/> auto-normalize string values to support quote removal in case of strings. Related to https://github.com/starship/starship/pull/3883 .
<csr-id-36e2fc0aff4e6aaa35335da90108918882d4cd16/> Use std::env::var_os() to avoid potential decode errors
<csr-id-469406dc0d9fece4a06230ef0d8018846202f0ad/> fix usage example in README.md
<csr-id-61af06b905926849abce19677ff4b9ac05d625a3/>
<csr-id-4b424ab73d20833deb0c674eeeeaaa8cc2358932/> add File::write_to_filter() to have a filter select the section to write.
This way, one can selectively write sections to a file, based on the section's origin
or other meta-data.
For convenience sake, most mutating methods on SectionMut can now be chained as well.
<csr-id-3fa86e1d01a75688cd8948a39ba415bcebfef02d/> add File::set_meta() to affect what metadata new sections receive.
That way it's possible to better control the metadata associated with new sections,
given that the config file metadata may not truly reflect its identity anymore since it
can be a combination from many different files with various sources.
<csr-id-5b9bffe8a5eec738e892224a7e18f98c8430d8a4/> SectionMut::push_with_comment(key, comment) to add a new variable with a comment.
This is useful for providing more information about a value at hand, especially if it was
added programmatically and then shows up in the configuration.
<csr-id-e4bf8f0072e60a7a2df94690c8d0b13b1f3038bb/> Add the Source::EnvOverride to have a place for 'terminal' overrides.
That way environment variables represented via git-configuration
can be integrated into git configuration, making clearer what's
going to happen even when looking at the configuration via
gix config.
The implementation has to be careful though about assureing there
is no more specific configuration key, like http.<URL>.proxy that
would override the one from the environment, which always has
the final word.
<csr-id-5fa95460db843f7dcfe68002b303b8b7649846dd/> comfort API like string_by_key(key) takes a key like "remote.origin.url", add section_by_key("remote.origin") as well.
That way it's the most comfortable way to query values and very
similar to how git does it, too.
Additionally, sections can be obtained by section key, both mutably and immutably for completeness.
<csr-id-7d7bd02d4e0678565f58c5da83fd1ad88c60e911/> read worktree specific configuration of main worktrees. Supporting this is useful when interacting with worktrees that have been created with sparse worktree support, which moves some configuration values into those for the worktree at hand.
Note that linked worktrees are not supported - for that use
git-repository instead.
<csr-id-aa5d66f60bd6c9ef404ebc120b613e0cf055b2c9/> add parse::section::header::is_valid_subsection() function.
It can be useful to validate subsection names without having to
construct an entire Header (which also includes a name).
<csr-id-5df2a2a5a9addbda7dcc68b2f8f7f4a48d9720c6/> Add various methods to iterate sections along with their id, and mutate them.
As section names are not unique, it was previously not possible to
iterate sections and then mutate them as one wouldn't be able to refer
to the exact section that was just traversed, after all, there can be
many sections named remote "origin".
With the new methods it's possible to uniquely refer to each section for mutation and removal.
<csr-id-9937d0e00df3a523484c7ae2850be2712a1a4c9a/> File::set_raw_value_filter() to set values only in sections passing a filter.
<csr-id-17455c9d93ad38bfee2560f5a4e60324dee3b4e5/> File::section_mut_or_create_new_filter() to allow chosing which sections to add values to.
<csr-id-5902f54b93101a6290fcf89f9f13fdbea3678e00/> File::section_mut_or_create_new(…) to obtain an existing or new section for mutation.
<csr-id-b1c40b0364ef092cd52d03b34f491b254816b18d/> use docsrs feature in code to show what is feature-gated automatically on docs.rs
<csr-id-517677147f1c17304c62cf97a1dd09f232ebf5db/> pass --cfg docsrs when compiling for https://docs.rs
<csr-id-1bc96bf378d198b012efce9ec9e5b244a91f62bc/> following includes is now non-fatal by default Otherwise it would be relatively easy to fail gitoxide startup, and we want to be closer to the behaviour in git which ignores most of the errors.
<csr-id-f9ce1b5411f1ac788f71060ecf785dda9dfd87bf/> File::from_git_dir() as comfortable way to instantiate most complete git configuration.
<csr-id-14a68a6a78a09f8ae56e30e3b7501de66ef31fdc/> File now compares actual content, ignoring whitespace and comments.
<csr-id-7dadfd82494d47e36d3f570988eaf3c6b628977f/> File::new_environment_overrides() to easily instantiate overrides from the environment.
<csr-id-146eeb064822839bc46fd37a247a1b9a84f64e40/> File::new_globals() can instantiate non-local configuration with zero-configuration.
<csr-id-e701e053fd05850973930be0cefe73e8f3604d40/> Source::storage_location() to know where files should be located.
<csr-id-fff088485dd5067976cc93d525903b39aafea76a/> file::ValueMut::(section|into_section_mut)() to go from value to the owning section.
This can be useful if the value was obtained using raw_value_mut().
<csr-id-f5f2d9b3fef98d9100d713f9291510fa4aa27867/> Source::is_in_repository() to find out if a source is in the repository.
<csr-id-91e718f0e116052b64ca436d7c74cea79529e696/> parse::key to parse a remote.origin.url-like key to identify a value
<csr-id-26147a7a61a695eda680808ee4aab44a890b2964/> Add File::detect_newline_style(), which does at it says.
<csr-id-0ad1c9a5280cc172432b5258e0f79898721bac68/> File::frontmatter() and File::sections_and_postmatter().
<csr-id-fc7e311b423c5fffb8240d9d0f917ae7139a6133/> parse::Event::to_bstr_lossy() to get a glimpse at event content.
<csr-id-09966a8ea4eaa3e0805e04188de86dd1bac9f388/> File::append() can append one file to another rather losslessly.
The loss happens as we, maybe for the wrong reasons, automatically
insert newlines where needed which can only be done while we still know
the file boundaries.
<csr-id-56ae5744e8957e617f3a0ebc4d725846b18d93f8/> file::Section::meta() to access a section's metadata.
<csr-id-6f97bf0c3e7164855cf5aa53462dbc39c430e03f/> File::sections() to obtain an iterator over all sections, in order.
<csr-id-5418bc70e67476f8778656f2d577f1f9aa65ffbe/> place spaces around key = value pairs, or whatever is used in the source configuration.
<csr-id-8118644625dc25b616e5f33c85f5100d600766e4/> proper escaping of value bytes to allow round-tripping after mutation
<csr-id-9f59356b4f6a1f5f7f35a62c9fbe4859bf8e8e5f/> whitespace in newly pushed keys is derived from first section value. That way, newly added key-value pairs look like they should assuming all keys have the same indentation as the first key in the section.
If there is no key, then the default whitespace will be double-tabs like what's commmon in git.
<csr-id-db1f34dfb855058ac08e97d4715876b5db712f61/> File::from_str() implementation, to support let config: File = "[core]".parse()?
<csr-id-9157717c2fb143b5decbdf60d18cc2bd99dde775/> whitespace in mutable sections can be finely controlled, and is derived from existing sections
<csr-id-ae3895c7882e0a543a44693faee5f760b49b54d7/> parse::Header::new(…) with sub-section name validation
<csr-id-d087f12eec73626eb327eaacef8ebb3836b02381/> Add parse::(Event|section::Header|Comment)::write_to(…).
Now it's possible to serialize these types in a streaming fashion and
without arbitrarily enforcing UTF-8 on it
<csr-id-5a8f242ee98793e2467e7bc9806f8780b9d320ce/> serde1 feature to add limited serde support
<csr-id-4726bb524c1b0935d35770c907d40a0a16dbb8b5/> GitConfig::integers()
Get multiple fully validated integer values, with their suffix
interpreted and checked for overflow.
<csr-id-ae22a4de486676f11469cec84be403903758b48b/> add GitConfig::integer()
A way to quickly obtain a valid integer with suffixes resolved
and overflow checked.
<csr-id-bfc263797226d027e04daaf6426e57183773d7c3/> GitConfig::strings() for multi-value strings.
<csr-id-7c75eac149c6ecb99c3dd7355d76d8d3e8b59cd0/> GitConfig::path() for direct access to paths.
Very similar to string(), but as path, whose query can never fail.
<csr-id-dc3dc3b41b5de3ec17429769747bf99bb2bdd03d/> support for try_value(), boolean() and string() access. Support for a convenient way of knowing if a value does or doesn't exist via try_value()`, which can only fail if the conversion fails.
Lastly, string() is a special case which doesn't fail as there is
no conversion, and boolean() allows to obtain a plain boolean value
if it was a valid boolean representation.
<csr-id-13554f8d21beb241e0fbdeb56b8414957cbee28a/> new hierarchical errors for value lookup
<csr-id-031bd2f401199a05d6465c0260ceed3cc849c7ac/> add suppport for android
Do not interpolate ~user/ on Android (Termux).
There is no meaning of it. It is single user system.
<csr-id-e4d6685064ad2b433f8acd3a74b320bf0169a994/> Add git_config::values::Path for a typesafe git path
Add a Path type to the git_config::values which
can be interpolated according to gits own path interpolation
rules.
<csr-id-e822f566dcff3f6c784c206dff2fbc5f82d543be/> implement a draft for subsection fetching
sections_by_name_with_header to allow iterating over tuples of
section header and section bodygit-config now uses git-config-value.GitConfig::from_paths(<paths>, …) accepts more inputs
<paths> is more flexible and is easier to use.<csr-read-only-do-not-edit/>
<csr-read-only-do-not-edit/>
<details><summary>view details</summary>
47d8162)6776a3f)8adf0d8)84cb256)4163c7f)a359cfd)GitConfig::from_paths(…, <option>) is now owned. (c7fcb5e)std::env::var_os() to avoid potential decode errors (36e2fc0)GitConfig::from_paths(<paths>, …) accepts more inputs (b04a346)72a5a02)GitConfig::integers() (4726bb5)GitConfig::integer() (ae22a4d)c139479)4408f17)GitConfig::strings() for multi-value strings. (bfc2637)7ea17e1)43a34a5)97e53f6)GitConfig::path() for direct access to paths. (7c75eac)values::*Error in favor of value::parse::Error. (38dfdcf)4612fca)732c0fa)try_value(), boolean() and string() access. ([dc3dc3b`](https://github.com/GitoxideLabs/gitoxide/commit/dc3dc3b41b5de3ec17429769747bf99bb2bdd03d))4496b5a)a98a7a7)8aef1d3)get_ prefixes from methods (a86b254)lookup::Error and lookup::existing::Error (f9aaac1)13554f8)cc2d810)f158648)git-path crate instead of git_features::path (47e607d)5fc5459)50ff7aa)06b86e0)4dc6594)5e0f889)330d0a1)Permissions as there is no need for that here. (1954ef0)1bc96bf)989603e)File::from_git_dir() as comfortable way to instantiate most complete git configuration. (f9ce1b5)acb4520)ec21e95)Env test utility into git-testtools (bd3f4d0)b073e29)e4d8fd7)dac1463)cfda0c3)3d89a46)8a7fb15)fbcf40e)97e5ede)ee10dd5)9c248ee)File now compares actual content, ignoring whitespace and comments. (14a68a6)6c1588f)f5580a3)4e47df5)File::resolve_includes() and move its error type to file::includes. (17c83d5)File::from_bytes_owned() and remove File::from_path_with_buf() (5221676)from_paths_metadata() . (612645f)61ecaca)File::new_environment_overrides() to easily instantiate overrides from the environment. (7dadfd8)45c964a)File::from_env_paths(). (98d45c2)File::new_globals() can instantiate non-local configuration with zero-configuration. (146eeb0)Source in accordance for what git actually does. (97374e4)Source::storage_location() to know where files should be located. (e701e05)file::ValueMut::(section|into_section_mut)() to go from value to the owning section. (fff0884)Source::is_in_repository() to find out if a source is in the repository. (f5f2d9b)parse::key to parse a remote.origin.url-like key to identify a value (91e718f)f7bd2ca)3c06f88)File::detect_newline_style(), which does at it says. (26147a7)78e85d9)5e8127b)88c6b18)file::init::… Option and Error types. (230a523)lossy load mode. (d003c0f)withfilter support. ([32d5b3c`](https://github.com/GitoxideLabs/gitoxide/commit/32d5b3c695d868ba93755123a25b276bfbe55e0a))a50a396)File::frontmatter() and File::sections_and_postmatter(). (0ad1c9a)_filter() versions to most access methods. (1ea26d8)50c1753)df94c67)parse::Comment::(comment_tag|comment) to ::tag|text and parse::Section::section_header to ::header. (3f3ff11)parse::Event::to_bstr_lossy() to get a glimpse at event content. (fc7e311)c70e135)25ed92e)File::append() can append one file to another rather losslessly. (09966a8)4665e87)file::Section::meta() to access a section's metadata. (56ae574)d60025e)File::sections() to obtain an iterator over all sections, in order. (6f97bf0)file::Metadata with each File. (6f4eea9)file::SectionBody to file::section::Body. (b672ed7)File::sections_by_name_with_header() as ::sections_by_name() now returns entire sections. (3bea26d)9aa5acd)resolve_includes options to make space for more options when loading paths. (41b3e62)path::Options into path::Context. (cabc8ef)207e483)0d07ef1)9750b7a)9cb9acb)Source type to allow knowing where a particular value is from. (c92d5c6)Boolean can use numbers to indicate true or false, drops support for one and zero. (6b90184)File are now using impl AsRef<str> where possible for added comfort. (3de0cfd)file::*Mut types thanks to impl Into/AsRef. (3d25fe6)Mutable* into $1Mut for consistency. (393b392)file::MutableSection::remove() now actually removes keys and values. (94dde44)ac843cb)701266e)file::MutableValue and file::MutableMultiValue. (0a7391a)file::MutableMultiValue escapes input values and maintains key separator specific whitespace. (048b925)key = value pairs, or whatever is used in the source configuration. (5418bc7)a7eff01)15cd1d2)511985a)7e03b83)8118644)afa736a)MutableValue showing that it's too buggy right now (5e6f9d9)file::MutableSection::set_leading_space() to set_leading_whitespace(). (83a0922)9f59356)File::from_str() implementation, to support let config: File = "[core]".parse()? (db1f34d)9157717)c88eea8)a0d6caa)ee9ac95)59ec7f7)a93a156)File::rename_section() with validation of input arguments. (895ce40)9a2f597)12cf005)parse::section::Header::new() by making its fields private. (219cf7a)parse::Header::new(…) with sub-section name validation (ae3895c)cfd974f)parse::section::Header (00592f6)00d1a9b)9fac8e0)78bb93c)File::write_to() and File::to_bstring(); remove some TryFrom impls. (4f6cd8c)Integer::to_bstring() as well as some TryFrom impls. (0e392f8)Boolean::to_bstring() along with a few From impls. (b22732a)parse::(Event|section::Header|Comment)::write_to(…). (d087f12)3d7fc18)value::normalize() handles escape sequences. (f911707)cf3bf4a)b92bd58)file::mutating (2d5703e)File::sections_by_name_with_header() (44dfec0)file::raw module (6acf4a4)b979a3b)eafc6ce)7aa8a0b)File::sections_by_name() and File::sections_by_name_with_header(). (65c520c)2abffd6)539c2f6)f1668e9)2599680)879fad5)b2b82da)ba69124)33efef6)700d6aa)Path::interpolate() now takes path::interpolate::Options instead of three parameters. (ac57c44)from_env (c8693f9)a7d7751)95fc20a)a361c7f)8e84fda)File::raw_multi_value() to File::raw_values() ([9cd9933](https://gitOne column per quarter.