Package Exports
- @wroud/git
- @wroud/git/IGitCommitInfo.js
- @wroud/git/IGitLink.js
- @wroud/git/IGitTrailer.js
- @wroud/git/defaultTagPrefix.js
- @wroud/git/getGitCommits.js
- @wroud/git/getGitLastSemverTag.js
- @wroud/git/getGitLastSemverTags.js
- @wroud/git/getGitPrefixedTag.js
- @wroud/git/index.js
- @wroud/git/package.json
- @wroud/git/validateGitEnvironment.js
Readme
@wroud/git
@wroud/git
is a lightweight toolset for working with local git repositories. It provides utilities to retrieve and parse git commits and tags, making it useful for building CI/CD workflows, especially for automated release processes based on conventional commits.
Features
getGitCommits: Retrieves a list of parsed git commits as an async generator. It supports filtering commits by a specified path (default:
'.'
) and a range of commits defined by thefrom
andto
parameters. You can limit the number of commits usingmaxCommits
. Additionally, the function can include associated tags, trailers (metadata in commits), and even custom trailers and links based on user-defined regular expressions.getGitLastSemverTag: Returns the most recent semantic version tag from the git history. By default, it checks up to
HEAD
and looks for tags with av
prefix, although both can be customized through theto
andprefix
parameters.
Installation
Install via npm:
npm install @wroud/git
Install via yarn:
yarn add @wroud/git
Documentation
For detailed usage and API reference, visit the documentation site.
Changelog
All notable changes to this project will be documented in the CHANGELOG file.
License
This project is licensed under the MIT License. See the LICENSE file for details.