chancegarcia / git-toolkit
create a change log based on your commit history and tags
Installs: 5
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 2
Type:project
Requires
- php: >=7.3
- czproject/git-php: ^3
- symfony/console: ^4.4
Requires (Dev)
- php-coveralls/php-coveralls: dev-master
- php-parallel-lint/php-console-highlighter: dev-master
- php-parallel-lint/php-parallel-lint: dev-master
- phpunit/phpunit: ^9
- roave/security-advisories: dev-master
- squizlabs/php_codesniffer: 4.0.x-dev
This package is auto-updated.
Last update: 2024-10-24 21:30:27 UTC
README
develop branch:
This toolkit only contains one tool currently. That tool will create a changelog.md
for a project using the git
repository tags and the git commit history.
Installation
composer require --dev chancegarcia/git-toolkit
General Usage
Unless specified in a config file, the repository found in the current working directory will be used.
Configuration (optional)
Default values for some command arguments and options can be set via a config file in
config/chancegarcia_git_toolkit.php
A .dist
file provides an example of configuration options.
The following values are configurable:
project_root
: the directory where the repository residesproject_name
: The main header valuefilename
: name of the markdown file to write out.output_directory
: path to where the markdown file should be written
ChangeLog Command Usage
./vendor/bin/toolkit toolkit:changelog toolkit:changelog
The changelog file will produce a markdown document with a main header (optionally set by the header argument)
of Projecty McProjectFace
. Tag names are the subheaders and the commits between the tags are printed after the
subheader
While you can run the base command, without a header argument, to produce a changelog, you might want to pass the a main
header argument with it. Unless you really want to have the top header be Projecty McProjectFace
(totally not judging)
.
./vendor/bin/toolkit toolkit:changelog toolkit:changelog "I am not a cat."
Prepare a new or initial release tag/number
If no tags are present. The subheader will be the commit id.
In order to "create" a new tag, use the --new-tag=<NEWTAG>
to set the new header and write all recent commits since
the previous tag (if there is one) into the changelog.
./vendor/chancegarcia/git-toolkit/bin/toolkit toolkit:changelog "We Love Kittens" --new-tag="1.0.0"