14.4.3 • Published 2 years ago

@jeromefitz/git-cz v14.4.3

Weekly downloads
48
License
MIT
Repository
github
Last release
2 years ago

🥳️ git(moji)-cz => @jeromefitz/git-cz

🍴️ Why this Fork

npm i -g git-cz
added 1 package in 0.612s

Installs in 0.6s vs 31.1s.

🍽️ But Why this Fork

I needed to customize some things, and seemed like the intent was breaking away from streamich/git-cz.

  • Package Upgrades
  • Node14 Support
  • Subject Customization
  • Theming: Gitmoji ✨️ (new default)
    • Semantic Versioning Requirements for CI/CD
  • Gitflow Brancing
    • CLI Customizations
  • Codestyle Preference
    • Getting there
  • TypeScript Migration
    • Eventually getting there

📝️ Note: @jeromefitz/git-cz-v7.0.0 is the main breaking off point

🔧️ Custom config

You can provide a custom configuration in a changelog.config.js file in your repo, or in any parent folder.

git-cz will search for the closest config file.

🚧️ Non-interactive mode

Using --non-interactive flag you can run git-cz non-interactive mode.

For example:

git-cz --non-interactive --type=feat --subject="add onClick prop to component"

CLI parameters:

  • --body
  • --breaking
  • --issues
  • --lerna
  • --scope
  • --subject
  • --type

:octocat: Commit

Subject via Format

By default the subject format is: {emoji} {scope} {branchName}{subject}

--format "{emoji} {scope} {branchName}{subject}"
{
  "commit": {
    "format": "{emoji} {scope} {branchName}{subject}"
  }
}

You can configure your own using the following fields:

  • {branchName}
  • {emoji}
  • {scope}
  • {subject}
  • {type}

These are the only fields that will be dynamically replaced by @jeromefitz/git-cz.

These are not ${type} so in your configuration if you need to pass dynamically values to format you can while keeping these separate. Helpful for when adding [skip ci] to format conditionally.

📝️ Note: If your configuration file is dynamic and you want to override these change yours at run time to ${type} 😅️. These fields are only replaced if they exist. Heck, you can have a format of: format: "static(hard): code value" if you really want (please do not).

branchName

This is really only useful if you are using an issue tracker like Jira.

▲ git-cz [ABC-1234] git-cz

Would pull ABC-1234 in for {branchName}

If you were doing something like:

▲ git-cz [feature/gitflow-branch-names]

You would not want to pass branchPrefix as that would be a long commit message.

Also most likely if you are doing feature branches you are doing ABC-1234's into it.

Types

From gitmoji:

  • access: Improve accessibility
  • analytics: Add or update analytics or track code
  • animation: Add or update animations and transitions
  • arch: Make architectural changes
  • assets: Add or update assets
  • beer: Write code drunkenly
  • breaking: Introduce breaking changes
  • build: Add or update development scripts
  • catch: Catch errors
  • ci: Add or update CI build system
  • clean: Deprecate code that needs to be cleaned up
  • compat: Update code due to external API changes
  • config: Add or update configuration files
  • contrib-add: Add or update contributor(s)
  • data: Data exploration/inspection
  • db: Perform database related changes
  • dep-add: Add a dependency
  • dep-rm: Remove a dependency
  • dep-up: Add or update compiled files or packages
  • deploy: Deploy stuff
  • docs: Add or update documentation
  • docs-code: Add or update comments in source code
  • downgrade: Downgrade dependencies
  • egg: Add or update an easter egg
  • experiment: Perform experiments
  • feat: Introduce new features
  • fix: Fix a bug
  • fix-ci: Fix CI Build
  • flags: Add, update, or remove feature flags
  • hotfix: Critical hotfix
  • i18n: Internationalization and localization
  • ignore: Add or update a .gitignore file
  • init: Begin a project
  • iphone: Work on responsive design
  • license: Add or update license
  • lint: Fix compiler / linter warnings
  • log-add: Add or update logs
  • log-rm: Remove logs
  • merge: Merge branches
  • mock: Mock things
  • mv: Move or rename resources (e.g.: files, paths, routes)
  • patch: Simple fix for a non-critical issue
  • perf: Improve performance
  • poo: Write bad code that needs to be improved
  • prune: Remove code or files
  • pushpin: Pin dependencies to specific versions
  • refactor: Refactor code
  • release: Release / Version tags
  • revert: Revert changes
  • rip: Remove dead code
  • roles: Work on code related to authorization, roles and permissions
  • security: Fix security issues
  • seed: Add or update seed files
  • seo: Improve SEO
  • snapshot: Add or update snapshots
  • style: Improve structure / format of the code
  • test: Add or update tests
  • texts: Add or update text and literals
  • types: Add or update types
  • typo: Fix typos
  • ui: Add or update the UI and style files
  • upgrade: Upgrade dependencies
  • ux: Improve user experience / usability
  • wip: Work in progress

Custom additivies:

  • chore: Changes that don’t modify src or test file
  • rollforward: Create rollforward version
  • run-build: Custom type for CI/CD to hook into run build override

Subject

The subject contains succinct description of the change:

  • Use the imperative, present tense: "change" not "changed" nor "changes"
  • No dot (.) at the end.

Body

Just as in the subject, use the imperative, present tense: "change" not "changed" nor "changes". The body should include the motivation for the change and contrast this with previous behavior.

Breaking Changes

Breaking Changes must start with the words BREAKING CHANGE:.

Husky

If you are using husky@5.x on your project that has git-cz as a local dependency please be cognizant of locally installed binaries:

If you were calling directly locally installed binaries, you need to run them via your package manager:

npx --no-install git-cz --hook || true
yarn git-cz --hook || true

Branch

Change the mode and create branches via gitflow:

git-cz -m branch

Roadmap

This is not going to be great to type, but may be good to move to:

  • https://github.com/commitizen/cz-cli and create adapter/plugins.
    • ⭐️ 11.k to 500
    • ⬇️ 373k to 23.9k
14.4.3

2 years ago

14.4.2

2 years ago

14.4.0

2 years ago

14.4.1

2 years ago

14.4.0-canary.2

2 years ago

14.4.0-canary.1

2 years ago

14.3.0-canary.1

2 years ago

14.3.0

2 years ago

14.3.1

2 years ago

14.2.2

2 years ago

14.2.3

2 years ago

14.2.4

2 years ago

14.2.5

2 years ago

14.2.6

2 years ago

14.1.4

2 years ago

14.2.0

2 years ago

14.2.1

2 years ago

13.3.1

2 years ago

14.1.0

2 years ago

14.1.1

2 years ago

14.1.2

2 years ago

14.1.3

2 years ago

14.0.10

2 years ago

14.0.9

2 years ago

14.0.0

2 years ago

14.0.1

2 years ago

14.0.2

2 years ago

14.0.3

2 years ago

14.0.4

2 years ago

14.0.5

2 years ago

14.0.6

2 years ago

14.0.7

2 years ago

14.0.8

2 years ago

13.3.0

2 years ago

12.0.4

2 years ago

12.0.5

2 years ago

12.0.6

2 years ago

12.0.0

2 years ago

12.0.1

2 years ago

12.0.2

2 years ago

11.2.0

2 years ago

11.2.1

2 years ago

13.0.0

2 years ago

11.1.3

3 years ago

13.1.1

2 years ago

12.0.6-canary.1

2 years ago

13.1.0

2 years ago

13.2.0

2 years ago

12.0.0-canary.3

2 years ago

12.0.0-canary.2

2 years ago

12.0.0-canary.4

2 years ago

12.0.0-canary.1

2 years ago

11.1.2

3 years ago

10.0.11

3 years ago

11.1.1

3 years ago

11.1.0

3 years ago

11.0.0

3 years ago

10.0.9

3 years ago

10.0.10

3 years ago

10.0.7

3 years ago

10.0.8

3 years ago

10.0.6

3 years ago

10.0.5

3 years ago

10.0.4

3 years ago

10.0.2

3 years ago

10.0.3

3 years ago

10.0.0

3 years ago

10.0.1

3 years ago

9.0.5

3 years ago

9.0.4

3 years ago

9.0.3

3 years ago

9.0.1

3 years ago

9.0.0

3 years ago

8.3.54

3 years ago

8.3.55

3 years ago

8.3.56

3 years ago

8.3.53

3 years ago

8.3.51

3 years ago

8.3.50

3 years ago

8.3.49

3 years ago

8.3.46

3 years ago

8.3.47

3 years ago

8.3.48

3 years ago

8.3.44

3 years ago

8.3.45

3 years ago

8.3.43

3 years ago

8.3.42

3 years ago

8.3.40

3 years ago

8.3.41

3 years ago

8.3.39

3 years ago

8.3.38

3 years ago

8.3.36

3 years ago

8.3.37

3 years ago

8.3.34

3 years ago

8.3.35

3 years ago

8.3.33

3 years ago

8.3.32

3 years ago

8.3.31

3 years ago

8.3.29

3 years ago

8.3.30

3 years ago

8.3.28

3 years ago

8.3.27

3 years ago

8.3.26

3 years ago

8.3.23

3 years ago

8.3.24

3 years ago

8.3.25

3 years ago

8.3.22

3 years ago

8.3.21

3 years ago

8.3.20

3 years ago

8.3.19

3 years ago

8.3.18

3 years ago

8.3.17

3 years ago

8.3.16

3 years ago

8.3.15

3 years ago

8.3.14

3 years ago

8.3.12

3 years ago

8.3.13

3 years ago

8.3.11

3 years ago

8.3.10

3 years ago

8.3.8

3 years ago

8.3.9

3 years ago

8.3.6

3 years ago

8.3.7

3 years ago

8.3.5

3 years ago

8.3.4

3 years ago

8.3.3

3 years ago

8.3.0-git-cz.3

3 years ago

8.3.0-git-cz.2

3 years ago

8.3.0-git-cz.1

3 years ago

8.3.2

3 years ago

8.3.1

3 years ago

8.2.3

3 years ago

8.2.2

3 years ago

8.2.5

3 years ago

8.2.4

3 years ago

8.2.1

3 years ago

8.2.0

3 years ago

1.0.0

3 years ago

6.2.1

3 years ago

7.0.0

3 years ago

7.1.1

3 years ago

7.0.2

3 years ago

7.1.0

3 years ago

7.0.1

3 years ago

8.0.0-canary.3

3 years ago

8.0.0-canary.4

3 years ago

8.0.0-canary.1

3 years ago

8.0.0-canary.2

3 years ago

8.1.0

3 years ago

8.0.0

3 years ago

8.0.0-canary.7

3 years ago

8.0.0-canary.5

3 years ago

8.0.0-canary.6

3 years ago

6.1.0

3 years ago

6.0.0

3 years ago

6.2.0

3 years ago

6.2.0-canary.1

3 years ago

5.1.0

3 years ago

5.0.0

3 years ago

5.0.0-main.1

3 years ago

5.0.0-canary.5

3 years ago

5.0.0-canary.4

3 years ago

5.0.0-canary.3

3 years ago

5.0.0-canary.2

3 years ago

5.0.0-canary.11

3 years ago

5.0.0-canary.9

3 years ago

5.0.0-canary.8

3 years ago

5.0.0-canary.7

3 years ago

5.0.0-canary.10

3 years ago

5.0.0-canary.6

3 years ago

5.0.0-canary.1

3 years ago

4.8.0-develop.2

3 years ago

4.8.0-develop.1

3 years ago

4.8.0-develop.0

3 years ago