- Added
gc::CollectableRefs::headfn returning a collectable head reference. - Added
objectmodule, includingDatabasetrait for retrieval of commits and trees, as well as traits for creating and interacting with those. - Added traits
remote::Nameandremote::Namesfor generating remote related parts of reference names and refspecs. - Added
referencemodule, including theReferenceandStoretraits for retrieving and interacting with references, as well as thePartsandKindtypes for extracting information from reference names. - Added
traversalmodule, including theTraversibleandTraversalBuildertraits for traversing the commit graph. - Added
basemodule including theBasetrait providing some associated types, serving as a base for other traits.
- Switched to Rust edition 2024.
- Fixed code style.
- Made
git2an optional dependency. - Rename
repository::RepositoryExttorepository::Repository. - Make
issue::Issue::idreturn a reference to an OID. - Made
gc::CollectableRefsgeneric over allrepository::Repositorytypes. - Made
issue::Issuegeneric over allrepository::Repositorytypes. - Made all
repository::RepositoryExtmethods provided methods based onreference::Storeand other traits. - Made
repository::RepositoryExtrequirereference::Store. - Made
repository::RepositoryExt::issue_with_messagerequireSelfto betraversal::Traversible. - Moved
repository::RepositoryExt::first_parent_messagestotraversal::Traversibletrait. - Made
repository::RepositoryExt::issue_with_messagetake the message's OID rather than a commit object. - Rewrote
error::Error, making it generic over the git-specific inner error type and allow for more inner error types.
- Removed
gc::CollectableRefs::push_ref_parentsfn. - Removed
gc::ReferenceCollectortype. - Removed
repository::Repository::colelctable_refsfn. - Removed
messagemodule and all items it provided. - Removed
Issue::ref_partandIssue::newfns. - Removed
itermodule and all items it provided. - Removed
repository::RepositoryExt::issue_messages_iterfn. - Removed
repository::RepositoryExt::empty_treefn. - Removed
error::ResultExtfrom the public API. It is now only used internally.
- Use
Results ofgit2::Revwalk::reset,git2::Revwalk::set_sortingandgit2::Revwalk::simplify_first_parent.
Changes:
- The library was split off the binary's tree. This is the new library tree.
- The library was made buildable with newer versions of rust (1.69) and dependencies were upgraded.
- Some traits in the library were refactored to not be generic over their functions return types, but rather use associated types for that.
Changes:
- The message formatting for the "show" subcommand was improved.
- In filter-specs for the "list" subcommand, a '=' is used for separating key and value when filtering for an exact value, rather than a ':'.
Added features:
- The "create-message", "new", "reply" and "tag" now accept the "--author" and "--date" options. Analogue to the options of "git commit" with the same name, the new options alter the author and authoring date of the resulting message.
- New "reporter-name" and "reporter-email" filter keys for issue filtering using the "list" subcommand. As the name suggests, the keys may be used for filtering issues based on the reporter's name or email.
- Filter specs for the "list" subcommand can now be used for filtering by substring or presence of a piece of issue metadata.
- Filter specs for the "list" subcommand can now be inverted.
Bug-fixes:
- Git-dit did not handle pager and editor flags correctly. For example,
configuring
less -Ras the pager (contrary toless) would cause git-dit search for a binary named "less -R", resulting in an error.
Changes:
LineIteratorExt::stripped()now returns an iterator which also strips trailing blank lines.Issue::new()now returns aResult.- Multi-line trailers parsed by the
Blocksiterator are represented as StringTrailerValuewith newlines separating the individual lines from the input. trailerwas promoted to a top-level module.message::accumulationwas moved totrailermessage::metadatawas moved totrailerand renamed tospec.MetadataSpecificationwas renames toTrailerSpec.PairsToTrailersandDitTrailersiterator was moved to newtrailers::itermodule.Trailersiterator was moved tomessage::blockmodule.DitTrailersis now a generic iterator adapter on top of an iterator overTrailers.
Added features:
- New
TrailingBlankTrimmerfor removing trailing blank lines from sequences of lines. - New
StrippingIterfor stripping messages of comments and unnecessary white space. - New
TrailerFiltertype for filtering based on trailers. - New
ValueMatchertype for matchingTrailerValues. - New
MessagesExtconvenience trait for iterators over messages. The trait provides accumulation functionality. - New
MultiAccumulatortrait for map-based accumulation of multiple trailers. - Implemented
DefaultforTrailerValue. - Implemented
CloneforValueAccumulator. - Implemented
From<Blocks>forTrailers
- Add documentation of internals as a
README.mdto the sources of both the binary and the library.
Changes:
- "tag" now doesn't require a local head reference to be present in advance.
- "check-message" does not require a repository to be present any more.
Added features:
- New git-config option "dit.remote-prios" controlling how remote references are chosen for various actions.
- New "mirror" subcommand for mirroring remote references as local ones.
- New "gc" subcommand for collecting old references.
- New "check-refname" subcommand for extracting information from reference names.
- The "list" subcommand now supports a small set simple filters for filtering issues based on metadata.
- "get-issue-metadata" can now be used for querying a single piece of metadata.
- Example server-side update hook for a dit-only policy for repositories with global unauthenticated push access.
Bug-fixes:
- "fetch" and "push" tried fetching/pushing issues multiple times under some circumstances.
- "list" and "get-issue-tree-init-hashes" reported issues multiple times under some circumstances.
Changes:
RepositoryExt::issues_with_prefix()andRepositoryExt::issues()now return a unique set of issues.Issue::update_head()now takes an additional parameter controlling whether an existing head reference is replaced.Issue::messages_revwalk()was replaced by newIssue::messages()function.Issue::first_parent_revwalk()was replaced by newIssue::first_parent_messages()function.- Function
Issue::find_local_head()was renamed toIssue::local_head(). Issue::local_refs()now has an additional parameter controlling the type of references returned.Issue::issue_leaves()was removed.message::linemodule was replaces bymessage::blockmodule, including associated types.LineIteratorExt::categorized_lines()was replaced byLineIteratorExt::line_blocks().Message::categorized_body()was replaced byMessage::body_blocks().TrailerValue::append()now operates in-place, on a mutable reference.
Added features:
- New type
Messagesfor iterating over messages. - New function
Issue::terminated_messages()for preparing aMessagesinstance which terminates at the initial message. - New function
Issue::messages_from()for creating aMessagesinstance returning messages from one specific commit to the initial message. - New module
message::accumulationfor accumulating issue metadata. - New module
message::metadataproviding specification of a small set of predefined pieces of issue metadata - New type
IssueRefTyperepresenting the type of a reference (e.g. "head" or "leaf"). - New
PairsToTrailersiterator for assembling trailers from key-value pairs. - New
Issue::remote_refs()andIssue::all_refs()functions for retrieving references. - Implemented
PartialEq,EqandHashforIssue. - Implemented
From<Messages>forIssueMessagesIter. - Implemented
AsRef<String>forTrailerKey
Bug-fixes:
- Fixed lifetimes of return values of several
Issuefunctions.
- Building the manpage is now controlled via the
manpagefeature rather than an environment variable. - The subcommand descriptions are now longer set as code snippets.
- Various small fixes and updates.
Changes:
- Add WORKFLOWS section to the man page
- Clarify implementation of metadata "tags" in the documentation
- Clarify membership of initial issue messages to branches in man page
- Fix punktuation issues in the man page
Bug-fixes:
- Fix bug in
Trailersiterator which caused emission of trailers even if they are embedded in a block of text.
Changes:
- Rewrite in Rust (single binary)
- Drop "prepare-metadata" script
- "push" and "fetch" now only support dummy auth and ssh-agent
- Updated README
- Updated man page
Added features:
- Documentation of data model, semantics and use-cases
- Library crate "libgitdit"
- Long options
Bug-fixes:
- Read editor from git config, fall back to default
(We previously relied on the
EDITORvariable.)
Initial prototype, written in bash.