Giter Site home page Giter Site logo

rzp1 / lerna-changelog Goto Github PK

View Code? Open in Web Editor NEW

This project forked from olehan/lerna-changelog

0.0 0.0 0.0 1.84 MB

:book: PR-based changelog generator with monorepo support but for GitLab

License: MIT License

JavaScript 0.87% TypeScript 99.13%

lerna-changelog's Introduction

lerna-changelog-gitlab

Forked from lerna-changelog

Everything is the name, expect it's integrated with Gitlab!

Latest NPM release

Gitlab PR-based changelog generator with monorepo support

Install

Install with yarn:

yarn add lerna-changelog-gitlab --dev
# or globally
yarn global add lerna-changelog-gitlab

We're using yarn but you can use npm if you like:

npm install --save-dev lerna-changelog-gitlab
# or globally
npm install --global lerna-changelog-gitlab

Usage

$ lerna-changelog-gitlab
## Unreleased (2018-05-24)

#### :bug: Bug Fix
* [#198](https://github.com/my-org/my-repo/pull/198) Avoid an infinite loop ([@helpful-hacker](https://github.com/helpful-hacker))

#### :house: Internal
* [#183](https://github.com/my-org/my-repo/pull/183) Standardize error messages ([@careful-coder](https://github.com/careful-coder))

#### Commiters: 2
- Helpful Hacker ([@helpful-hacker](https://github.com/helpful-hacker))
- [@careful-coder](https://github.com/careful-coder)

By default lerna-changelog-gitlab will show all pull requests that have been merged since the latest tagged commit in the repository. That is however only true for pull requests with certain labels applied. The labels that are supported by default are:

  • breaking (:boom: Breaking Change)
  • enhancement (:rocket: Enhancement)
  • bug (:bug: Bug Fix)
  • documentation (:memo: Documentation)
  • internal (:house: Internal)

You can also use the --from and --to options to view a different range of pull requests:

lerna-changelog-gitlab --from=v1.0.0 --to=v2.0.0

Monorepo support

If you have a packages folder and your projects in subfolders of that folder lerna-changelog-gitlab will detect it and include the package names in the changelog for the relevant changes.

GitHub Token

Since lerna-changelog-gitlab interacts with the GitLab API you may run into rate limiting issues which can be resolved by supplying a "personal access token":

export AUTH_TOKEN="..."

You'll need a personal access token for the GitLab API with the read_repository scope for your private repositories.

Configuration

You can configure lerna-changelog-gitlab in various ways. The easiest way is by adding a changelog key to the package.json file of your project:

{
  // ...
  "changelog": {
    "labels": {
      "feature": "New Feature",
      "bug": "Bug Fix"
    }
  }
}

The supported options are:

  • repo: Your "org/repo" on GitHub (automatically inferred from the package.json file)

  • nextVersion: Title for unreleased commits (e.g. Unreleased)

  • labels: GitHub PR labels mapped to changelog section headers

  • ignoreCommitters: List of committers to ignore (exact or partial match). Useful for example to ignore commits from bots.

  • cacheDir: Path to a GitHub API response cache to avoid throttling (e.g. .changelog)

License

lerna-changelog is released under the MIT License.

lerna-changelog's People

Contributors

alex-pex avatar dcyriller avatar dependabot-preview[bot] avatar emmenko avatar ericandrewlewis avatar fson avatar gigabo avatar hzoo avatar jamiebuilds avatar jonaskello avatar olehan avatar rwjblue avatar shrikanthkr avatar trivikr avatar tuchk4 avatar turbo87 avatar

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.