Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

czg-ex

danyow8MIT1.6.3

Interactive Commitizen CLI that generate standardized git commit message

openai, commit, commit CLI, commit message, commitizen, commitizen-cli, cli, cz-git, cz-customizable

readme

czg

Interactive Commitizen CLI that generate standardized git commit message

CLI-Link awesome-cli-app
GitHub Repo stars
npm homebrew

Github   |   Installation   |   Website   |   简体中文文档



  • 🤖 OpenAI Support. Let the AI generate your git commit message description.
  • ⚡️ Lightweight : Zero Dependencies (1.5MB)
  • 🤗 Simpler and Faster : No plugin, No adapter, No extra steps, You can use npx | npm script | global install... quick start CLI in your any project
  • 😎 Highly Customizable : Internally contains the core of cz-git. Extend all the features of cz-git. Same behavior, Same configuration loader... You can customize the commit CLI according to your need

demo

Quick start

  1. Now try it out, use npx czg in your any projects
  2. And then, let's try to simply configure it. Create a .czrc file in the project root directory
{
  "scopes": [
    "hello",
    "world"
  ]
}

Note More information about configure file and options. See → Config

Features and Help

$ czg --help
NAME:
    czg - Interactive Commitizen CLI that generate standardized git commit message

WEBSITE:
    https://cz-git.qbb.sh/cli/
    https://github.com/Zhengqbbb/cz-git

SYNOPSIS:
    czg [subcommand...] [options...] [git-commit-options...]

SUBCOMMAND:
    ai               Turn on OpenAI generate subject mode
    break            Turn on appends a ! after the type/scope
    emoji            Turn on output message with emoji mode
    checkbox         Turn on scope checkbox mode
    gpg              Turn on use GPG sign commit message

OPTIONS:
    --config=        Specify the configuration file to use
    --openai-token=  Setup OpenAI API secret key to local (.config/.czrc)
    -N=,--ai-num=    Setting AI return number subjects and Turn on choose mode
    :, --alias       Directly submit the defined commit message
    -r, --retry      Directly retry submit by the last message
    -h, --help       Show help
    -v, --version    Show version

EXAMPLES:
    czg
    czg emoji
    czg :fd
    czg --config="./config/cz.json"
    czg --openai-token="sk-XXXXX"
    czg ai -N=3

Extends 'git commit' options.
See 'git commit --help' for more information.

Installation

npm install -g czg

MacOS:

brew install czg

⇒ Get Started (more installation and usage)

Configure

⇒ Configure Template

⇒ Show Related

⇒ Engineering Related

Recipes

⇒ Recipes

FAQ

⇒ FAQ

Projects using czg CLI

Nx logo
Nx
Element Plus logo
Element Plus
TDesign-Vue-Next logo
TDesign-Vue-Next
Vben-Admin logo
Vben-Admin

LICENSE

MIT Copyright (c) 2022-present Qiubin Zheng zhengqbbb@gmail.com (https://github.com/Zhengqbbb)

I just do my best to make thing well, Could you give a star ⭐ to encourage me ?

changelog

1.6.1 (2023-03-22)

Bug Fixes

  • cz-git: allowEmptyScopes not work when not provide scopes (ee0f045), closes #109

1.6.0 (2023-03-11)

Features

  • cz-git,cli: add aiType option to switch openAI model (#102) (e956ca0), closes #101
  • cz-git,cli: add JSON schema provide to JSON configure e.g .czrc (c113e53)
  • cz-git,czg: add modify message with prompt on AI confirm (#103) (59b55c7)

1.5.3 (2023-03-04)

Features

  • cz-git,cli: add --api-proxy to setup openai api http proxy (close #98)(#100) (f673262)

1.5.2 (2023-03-04)

Features

  • cz-git,cli: add HTTPS proxy support for OpenAI API requests (#97) (0de320a)

1.5.1 (2023-03-02)

Features

  • cz-git,cli: use gpt-3.5-turbo openai model (#96) (5018654)

1.5.0 (2023-02-18)

Features

  • cz-git.czg: support use OpenAI to generate commit subjects (#93) (3184e19), closes #92

1.4.1 (2022-12-11)

Features

  • cz-git,cli: add confirmCommit in skipQuestions #86 (#88) (1167109)

1.4.0 (2022-12-04)

Bug Fixes

  • fix(cz-git,czg)!: fix typo option issuePrefixs field #82 (#84) (febeba9)

Features

  • cz-git,czg: add scopesSearchValue boolean option field #83 (#85) (867eb87)

⚠ BREAKING CHANGES

  • cz-git,czg: rename option typesSearchValueKey to typesSearchValue
    • Already processed for normal compatibility
  • cz-git,czg: main fix issuePrefixs typo field
    • Current version has been already processed for normal compatibility
    • But I also hope that you can modify this message as soon as possible
{
  message: {
-   footerPrefixsSelect
+   footerPrefixesSelect

-   customFooterPrefixs
+   customFooterPrefix
 }

-   issuePrefixs
+   issuePrefixes

-   customIssuePrefixsAlign
+   customIssuePrefixAlign

-   emptyIssuePrefixsAlias
+   emptyIssuePrefixAlias

-   customIssuePrefixsAlias
+   customIssuePrefixAlias

-   allowCustomIssuePrefixs
+   allowCustomIssuePrefix

-   allowEmptyIssuePrefixs
+   allowEmptyIssuePrefix
}

Co-authored-by: Chris

1.3.12 (2022-10-21)

Bug Fixes

  • cz-git,czg: add ignore commitlint warning max length rule #72 (closed #71) (46346b4)

Features

  • plugin-loader: add cz.config.cjs config profiles (#73) (a915085)

⚠ BREAKING CHANGES

  • plugin-loader: remove .cz.js default loaded configure file The configuration items. see: Configure Template

1.3.11 (2022-08-21)

Bug Fixes

  • cz-git: fix breaking change break line default format (c073ec7)
  • cz-git: fix empty custom output 'CUSTOM' value (d1475d5), closes #55

Features

  • cli: support GPG sign commit message (c9caa97), closes #58
  • cz-git: add formatMessageCB can custom finally commit message (754c738), closes #57
  • cz-git: support types fuzzy search types[name] options (ba4ce71), closes #57

1.3.10 (2022-07-23)

Features

  • cli: add git-czg git enter command (de4d7ed)
    • Can use git czg to start czg CLI
  • cli: optimize czg retry option cache error message (#48) (757517b)
  • cz-git,cli: optimize the prompt msg when alias undefined (40bd1a2)

Other

1.3.9 (2022-07-01)

Features

1.3.8 (2022-06-26)

Bug Fixes

  • cli: remove BREAKINGCHANGE question limit when czg break (1bf9a72)

1.3.7 (2022-06-25)

Bug Fixes

  • cz-git: remove markBreakingChangeMode restrictions on BREAKINGCHANGE footer (a745bf2), closes #38

1.3.6 (2022-06-25)

Features

Performance Improvements

  • cz-git: cz-git packages size 1.7MB => 1.5MB (665d509)
  • cz-git: change bundle strategy | reduce 0.14MB (1f1e746), closes #37

1.3.5 (2022-06-16)

Features

  • cz-git: optimize scope list for empty #35 (#34) (4a38b92)

  • cz-git: add defaultFooterPrefix provide custom footer prefix (90f473b)

Refactor

  • site: new website deploy | use vitepress (d2a310e)

see: https://cz-git.qbb.sh/

1.3.4 (2022-06-04)

Features

  • cz-git: use complete-input inquirer plugin replace input (ca133bf), closes #32
  • plugin-inquirer: add ansiEscapes to control corsor move (e8dac95), closes #32
  • plugin-inquirer: add complete-input inquirer plugin (b20bbc1), closes #32
  • plugin-inquirer: checkbox and list support use tab key move down list (e38ed9f), closes #32

1.3.3 (2022-05-28)

Features

  • cz-git: add defaultType options (51f79c8), closes #30
  • cz-git: add scopeFilters options to filter scopes item (86e95a7), closes #30
  • plugin-loader: add more configure file to enhance js define (54bd3ab), closes #30
  • plugin-loader: support function option and can custom define config path (4db5914), closes #30
$ npm i -D cz-git

+ cz-git@1.3.2
added 1 package from 1 contributor and audited 1 package in 0.461s

$ du -sh ./node_modules
1.7M ./node_modules/cz-git/

1.3.2 (2022-05-21)

Features

  • cz-git: add theme color for prompt inquirer (d776149), closes #28
  • cz-git: use search-list replace autocomplete (5dbe4e2), closes #28
  • plugin-inquirer: checkbox support theme color configure (8c2effe)
  • plugin-inquirer: done search-list inquirer plugin (ad12f75), closes #28

Performance Improvements

  • :zap: update tsup bundle build cz-git (0e15e1c)
$ npm i -D cz-git

+ cz-git@1.3.2
added 1 package from 1 contributor and audited 1 package in 0.47s

$ du -sh ./node_modules
1.8M ./node_modules/cz-git/

1.3.1 (2022-05-14)

$ npm i -D cz-git

+ cz-git@1.3.1
added 1 package from 1 contributor and audited 1 package in 0.611s

$ du -sh ./node_modules
5.6M ./node_modules/cz-git/

Bug Fixes

  • plugin-inquirer: bump inquirer version (1111fda)

1.3.0 (2022-05-14)

Bug Fixes

  • cz-git: fix emoji and checkbox subcmd usage (9efe275)

Features

  • cz-git: add get command arg to set useEmoji and enableMultipleScopes (2cebeea)
  • cz-git: configure loader extract, perf load speed (d4ec683), closes #24 #25
  • cz-git: update ci defalut emoji code: ferris_wheel (4df8de8)

BREAKING CHANGES

  • cz-git: No supprt typescript config define file. commitlint.config.ts

1.2.9 (2022-05-12)

Bug Fixes

  • cz-git: fix empty scope err validate for not allow empty (654f75f)

Features

  • cz-git: add multiple scopes mode (89470d9), closes #14
  • plugin-inquirer: add figures symbols (3eea116)
  • plugin-inquirer: add separator option for checkbox multiple (3eaab45)
  • plugin-inquirer: add style util Fuc to output colorizen of prompt (9c48ace)
  • plugin-inquirer: done checkbox inquirer plugin for multiple (26b54c5), closes #14
  • plugin-inquirer: done the checkbox core render (2849162), closes #14

1.2.8 (2022-04-30)

Features

  • cz-git: use fuzzy search for type, scope and issues list (b82fbf9), closes #22
  • plugin-inquirer: add fuzzy match str util funtion (efde652), closes #22
  • plugin-inquirer: add fuzzyFilter util Fuc provide cz-git (83f773e), closes #22

1.2.7 (2022-04-27)

Bug Fixes

1.2.6 (2022-04-27)

Bug Fixes

  • cz-git: fix breaking char priority than maxNumber (4f463fa)

Features

  • cz-git: support single item intelligent filter ouput of scope and issueprefix (73f688c), closes #12
  • cz-git: upgrade inquirer dep version 8.2.2 (fbbf429)

Reverts

  • cz-git: fix getSingleParams use error param (3c32415)

1.2.5 (2022-04-23)

Bug Fixes

  • cz-git: both check the scope empty rule use ruleIsNotApplicable (3545cce), closes #15
  • cz-git: use strict empty scope strategy (ba44c8d), closes #12 #15

1.2.4 (2022-04-23)

Bug Fixes

  • cz-git: fix custom scope skip allowEmptyScopes check (f0d8c53), closes #16
  • cz-git: fix minor issues in default messages (99d8cc4)

Features

  • cz-git: add strict issuePrefixs configure (f2d11a9), closes #12
  • cz-git: allowEmptyScopes can base on ["scope-empty"] rule (4d3eff9), closes #15
  • cz-git: use defaultScope can star item of scope list (b899d2c), closes #16

1.2.3 (2022-04-07)

Features

  • cz-git: add typesAppend options to add extra types to default types (8e8d4cc)

1.2.2 (2022-03-30)

Features

  • cz-git: add max string number to break line for Body and BreakingChange (e9fe6ae), closes #6

1.2.1 (2022-03-11)

Bug Fixes

  • cz-git: fix limit length defind commitlint config (f602c9e)

1.2.0 (2022-03-06)

Features

  • guide: done cz-git website page and guide document (941bbe7), closes #4

1.1.8 (2022-03-04)

Features

  • cz-git: add auto get issue id (05ae340)

BREAKING CHANGES

1.1.7 (2022-03-03)

Features

  • cz-git: keep inquirer dep version same lerna inquirer version (a2de902)

1.1.3 (2022-03-03)

Features

  • cz-git: init monorepo project (ef6f30d), closes #2
  • cz-git: reduce commitizen dev number and lock commitilint load (2b207be), closes #2
  • cz-git: reduce commitlint type dev (8427b2b)
  • cz-git: reduce editor dev (d709130)
  • cz-git: reduce inquirer dev number (7efb64f)
  • cz-git: reduce word-wrap and temp dev number (e94f05a), closes #2

1.1.2 (2022-03-03)

Features

  • cz-git: init monorepo project (ef6f30d), closes #2
  • cz-git: reduce commitizen dev number and lock commitilint load (2b207be), closes #2
  • cz-git: reduce commitlint type dev (8427b2b)
  • cz-git: reduce editor dev (d709130)
  • cz-git: reduce word-wrap and temp dev number (e94f05a), closes #2

1.1.2 (2022-03-03)

Features

  • cz-git: init monorepo project (ef6f30d), closes #2
  • cz-git: reduce commitizen dev number and lock commitilint load (2b207be), closes #2
  • cz-git: reduce commitlint type dev (8427b2b)
  • cz-git: reduce editor dev (d709130)
  • cz-git: reduce word-wrap and temp dev number (e94f05a), closes #2

1.1.1 (2022-02-28)

Bug Fixes

  • cz-git: fix footerPrefix custom (fc8dc78)

1.1.0 (2022-02-28)

Features

  • cz-git: done document README.Marks the official version release (31e8b4d), closes #1

1.0.9 (2022-02-27)

⚠ BREAKING CHANGES

  • cz-git: - customScopesAlign and customIssuePrefixsAlign: can change align in selet
  • emptyScopesAlias, customScopesAlias, emptyIssuePrefixsAlias, customIssuePrefixsAlias: can change name of the prompt show

Features

  • cz-git: add align and alias option for selector (5be93a5), closes #1
  • cz-git: add allowEmptyScopes, allowCustomScopes to control disable (e0becb6), closes #1

Bug Fixes

  • cz-git: fixed use both maxHeaderLength and maxSubjectLengt (659b8eb), closes #1

1.0.8 (2022-02-24)

⚠ BREAKING CHANGES

  • feat: allowCustomScopes and allowCustomScopes control disable
  • feat: scopes can auto load value from commitlint
  • cz-git: - customScopesAlign and customIssuePrefixsAlign: can change align in selet
  • emptyScopesAlias, customScopesAlias, emptyIssuePrefixsAlias, customIssuePrefixsAlias: can change name of the prompt show

Features

  • cz-git: add align and alias option for selector (5be93a5), closes #1
  • cz-git: add allowEmptyScopes, allowCustomScopes to control disable (e0becb6), closes #1

1.0.7 (2022-02-22)

⚠ BREAKING CHANGES

  • cz-git: confirmColorize option: Prompt final determination whether to display the color

Features

  • cz-git: add confirmColorize option to handle confirm colorize (68b2629), closes #1

1.0.6 (2022-02-21)

⚠ BREAKING CHANGES

  • cz-git: add option breaklineChar

Features

  • cz-git: add breaklineChar option to make new line for body and BreakingChanges (6691c26), closes #1

1.0.5 (2022-02-21)

Features

  • cz-git: support both head and subject max rules (2444724), closes #1

1.0.4 (2022-02-19)

⚠ BREAKING CHANGES

  • cz-git: Need open option useEmoji

Features

  • cz-git: :sparkles: support commit add emoji (dd7d9e0), closes #1

1.0.3 (2022-02-19)

⚠ BREAKING CHANGES

  • cz-git: e.g: { value: "cz-git", name: "cz-git: core control" }

Features

  • cz-git: scopes config support value to add descrition for selector (980f163), closes #1

1.0.2 (2022-02-18)

⚠ BREAKING CHANGES

1.0.1 (2022-02-18)

Features

  • config: add standard-version to generate CHANGELOG (08f5b77)

Bug Fixes

  • cz-git: fix package main enter file path (a1ec4e0)

1.0.0 (2022-02-18)

Features

  • cz-git: done commit prompt overall process (bfb969c), link #1