diff --git a/README.md b/README.md index 8833048..3341048 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,11 @@ # commitizen +[![test](https://github.com/shipengqi/commitizen/actions/workflows/test.yml/badge.svg)](https://github.com/shipengqi/commitizen/actions/workflows/test.yml) +[![codecov](https://codecov.io/gh/shipengqi/commitizen/branch/main/graph/badge.svg?token=SMU4SI304O)](https://codecov.io/gh/shipengqi/commitizen) +[![Go Report Card](https://goreportcard.com/badge/github.com/shipengqi/commitizen)](https://goreportcard.com/report/github.com/shipengqi/commitizen) +[![release](https://img.shields.io/github/release/shipengqi/commitizen.svg)](https://github.com/shipengqi/commitizen/releases) +[![license](https://img.shields.io/github/license/shipengqi/commitizen)](https://github.com/shipengqi/commitizen/blob/main/LICENSE) + Command line utility to standardize git commit messages, golang version. Forked from [commitizen-go](https://github.com/lintingzhen/commitizen-go). The [survey](https://github.com/AlecAivazis/survey) project is no longer maintained. Therefore, this project uses [bubbletea](https://github.com/charmbracelet/bubbletea) instead. @@ -13,8 +19,9 @@ Usage: commitizen commitizen [command] -Available Commands: - init Initialize this tool to git-core as git-cz. +Available Commands: + init Install this tool to git-core as git-cz. + version Print the version information. help Help about any command Flags: @@ -38,7 +45,7 @@ $ git cz Download the pre-compiled binaries from the [releases page](https://github.com/shipengqi/commitizen/releases) and copy them to the desired location. -Then initialize this tool to git-core as git-cz: +Then install this tool to git-core as git-cz: ``` $ commitizen init ``` diff --git a/cmd/cz/init.go b/cmd/cz/init.go index 445711d..386d55b 100644 --- a/cmd/cz/init.go +++ b/cmd/cz/init.go @@ -12,8 +12,9 @@ import ( func NewInitCmd() *cobra.Command { c := &cobra.Command{ - Use: "init", - Short: "Initialize this tool to git-core as git-cz.", + Use: "init", + Aliases: []string{"install"}, + Short: "Install this tool to git-core as git-cz.", RunE: func(_ *cobra.Command, _ []string) error { src, err := exec.LookPath(os.Args[0]) if err != nil { @@ -23,7 +24,7 @@ func NewInitCmd() *cobra.Command { if err != nil { return err } - fmt.Printf("Init commitizen to %s\n", dst) + fmt.Printf("Install commitizen to %s\n", dst) return nil }, }