0.2.2 • Published 1 year ago

cli-release-note v0.2.2

Weekly downloads
-
License
-
Repository
github
Last release
1 year ago

CLI Release Note

CLI tool to help creating release note visually and easily.

!WARNING This tool is in Beta release, and main contain issues, feel free to open your own PR to help fix it.

How it works

It uses the outpout of a git log between tags or branches to input data into a static website, and then it opens this website locally in your default browser so you can visually selected the commits and create more readable release notes easily.

Install

Install the package globally, to be able to run it from any repository.

npm install cli-release-note -g

Run

Open the terminal inside a git repository, cli-release-note uses the local git data and commands to generate the commits preview for you.

Now input the release into your terminal:

release -current tag/branch -latest tag/branch

eg:

release -current v1.2.0 -latest v.1.1.0 
release -c v1.2.0 -l v.1.1.0 
release -current feature/Login-page -latest main 

After running the command if everything goes without error, a new tab will open in your default browser, listing all the commits from the tags/branches, and a text editor to easily create your releases note.

Command arguments

ArgumentsAliasDescription
currentcthe current tag or branch to be released
latestlthe latest tag or branch on production to be released

!WARNING cli-release-note does a git log current..latest diff comparison.

In case of no tag or branch match, the terminal you show you the git error, if you are referring to a local tag or branch, make sure you have it locally.

Run project locally

Install all dependencies

npm ci

This project consist in two parts, the CLI that will gather information from git and create a js file with all commits inside an array.

And the web app that presents the commits from the created file and the text editor.

CLI

cli.js contains the logic of the cli, it's a plain js run by node when the user enters "release" in the terminal.

To test changes locally first build the project:

npm run build

Then install the package globally:

npm install -g .

Now you can run the release command in your terminal. When making to change to cli.js build it again with this command:

npm run build:cli

This will make sure to add your changes you mad inside cli.js to the build, without re-building the entire web app

Web App

Assuming you have installed all dependencies, run:

npm run dev

This will start a server on port 9000, with the web app, using a fake content, that comes from ./src/git-log.js, or if you have run the command before, will show the latest commits from that time.

0.2.1

1 year ago

0.2.2

1 year ago

0.1.10

1 year ago

0.2.0

1 year ago

0.1.4

1 year ago

0.1.3

1 year ago

0.1.2

1 year ago

0.1.1

1 year ago

0.1.0

1 year ago