Giter Club home page Giter Club logo

gchl's Introduction

gchl

A Go-written Changelog Generator. Create Changelogs based on GitHub pull requests.

Installation

go install k8c.io/gchl@latest

Usage

You will need a GitHub personal access token for API calls, create one here. You can pass the token to gchl via the environment variable GCHL_GITHUB_TOKEN.

The generate is configured with a version to generate the changelog for. It will automatically determine the commit range by scanning the given repository and will then extract all release notes from all commits in the determined range. The changes are then cleaned up, grouped and printed to stdout as Markdown.

export GCHL_GITHUB_TOKEN=MYTOKENHERE
gchl --organization kubermatic --repository kubermatic --for-version v2.21.0

Use --verbose to see the API calls being made.

Get release notes via PR message annotation

In your pull request use a Markdown code block annotated with release-note (Don't copy paste the example below as it uses ' ;))

'''release-note
This text will be visible in changelog
'''

You can include multiple release notes in the same block; each one needs to be a single line and begin with either * or -. Note that if you include multiple notes, they will be sorted individually and might not appear right next to each other in the generated changelog.

Change Types

By default, gchl reads the labels from pull requests and uses the first one that starts with kind/ as the change's type (with the kind/ prefix stripped). If no such label exists, the release-note block can also be annotated with the type by adding it right next to release-note:

'''release-note bugfix
The important functionality has been fixed
'''

Overview

Usage of ./gchl:
  -e, --end string            Commit hash where to stop (instead of following the branch until the previous version)
  -v, --for-version string    Name of the release to generate the changelog for
  -o, --organization string   Name of the GitHub organization
  -r, --repository string     Name of the repository
  -V, --verbose               Enable more verbose logging

gchl's People

Contributors

dependabot[bot] avatar embik avatar kdomanski avatar mrincompetent avatar xrstf avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gchl's Issues

Build failure (cannot use type)

go get -v fails on Ubuntu 18.04 with the following error:

./commands.go:21:43: cannot use c (type *"github.com/urfave/cli".Context) as type *"github.com/kubermatic/gchl/vendor/github.com/urfave/cli".Context in argument to action.GenerateChangelogBetween
./commands.go:35:41: cannot use c (type *"github.com/urfave/cli".Context) as type *"github.com/kubermatic/gchl/vendor/github.com/urfave/cli".Context in argument to action.GenerateChangelogSince

Allow grouping by labels

Since https://github.com/kubermatic/dashboard now has multiple components, it would nice if gchl could split a generated changelog by labels, e.g. when grouping by sig/api and sig/ui, it will filter PRs based on that and create two separate sections that hold all changes (while still maintaining the existing structure of grouping by kind labels below that) for the respective part/module of the repository.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.