git-chlog

Crates.iogit-chlog
lib.rsgit-chlog
version0.1.0
sourcesrc
created_at2021-07-08 12:12:12.209428
updated_at2021-07-08 12:12:12.209428
descriptionRelease changelog generator for Git-enabled projects
homepage
repositoryhttps://github.com/DenysVuika/git-changelog
max_upload_size
id420307
size25,047
Denys Vuika (DenysVuika)

documentation

README

Git Changelog

Simple tool for release changelog reports with multiple template support.

Features

  • Supports multiple output templates
  • Handlebars templating language support
  • Excludes bots noise from the output (Dependabot, etc.)

Usage

You can get usage details by running the command with the --help argument:

./git-chlog --help
USAGE:
    git-chlog [FLAGS] [OPTIONS] <range>

ARGS:
    <range>    Commit range, i.e. master..develop

FLAGS:
    -h, --help       Prints help information
    -v, --verbose    Verbose output
    -V, --version    Prints version information

OPTIONS:
    -c, --config <path>          Sets a custom config file [default: default.conf]
    -d, --dir <path>             Working directory [default: .]
    -n, --max-count <number>     Limit the number of commits to output
    -o, --output <output>        Output file, will use console output if not defined
        --skip <number>          Skip number commits before starting to show the commit output
    -t, --template <template>    Path to the custom output template

Usage Examples

# generate release log with markdown format using changes between develop and master branches
./git-chlog -d ~/github/my-app master..develop > v1.md

# generate release log with HTML format using changes between develop and master branches
./git-chlog -d ~/github/my-app master..develop -t ./assets/templates/html.hbs > v1.html

Templates

The tool supports Handlebars templating language.

Output templates:

  • Markdown (default) (assets/templates/md.hbs)
  • HTML (assets/templates/html.hbs)

Simple Markdown template example looks like the following:

# Changelog

{{#each commits as |commit|}}
 - [{{commit.hash}}]({{../repo_url}}/commit/{{commit.hash}}) {{commit.subject}}
{{/each}}

Building

# debug build
cargo build

# release build
cargo build --release

License

MIT License, see LICENCE for more details.

Commit count: 20

cargo fmt