npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

cz-conventional-changelog-zh-cn

v0.0.7

Published

A fork of cz-conventional-changelog, and has been sensibly localized into Simplified Chinese.

Downloads

24

Readme

cz-conventional-changelog-zh-cn

npm version npm downloads

English | 简体中文

符合 conventional changelog 标准的 简体中文版 提示适配器,cz-conventional-changelog 的分叉(Fork)版本。

🪧 如果你更喜欢可以应用于多项目(multi-repo)的集成好的模板,可以去作者的 cz-conventional-template-zh-cn 瞧一瞧,也许更适合你。

截图

提交

日志

配置

package.json

与 commitizen 类似,可以通过 package.json 文件中的 config.commitizen 键来指定 cz-conventional-changelog-zh-cn 的相关配置,可配置项如下:

{
// ...
    "config": {
        "commitizen": {
            "path": "./node_modules/cz-conventional-changelog-zh-cn",
            "disableScopeLowerCase": false,
            "disableSubjectLowerCase": false,
            "maxHeaderWidth": 100,
            "maxLineWidth": 100,
            "defaultType": "",
            "defaultScope": "",
            "defaultSubject": "",
            "defaultBody": "",
            "defaultIssues": "",
            "types": {
              "feat": {
                "description": "添加新功能或功能性变化"
              },
              "fix": {
                "description": "修复 bug"
              },
              "docs": {
                "description": "只修改了文档"
              },
              "style": {
                "description": "修改了代码风格,不影响代码运行的变更"
              },
              "refactor": {
                "description": "重构代码,既不新增功能,也不是修复 bug"
              },
              "perf": {
                "description": "提升性能的代码更改"
              },
              "test": {
                "description": "增加或修改测试用例"
              },
              "build": {
                "description": "对构建过程或辅助工具和库的更改"
              },
              "chore": {
                "description": "对构建过程或辅助工具和库的更改"
              },
              "ci": {
                "description": "用于对持续集成(CI)配置文件和脚本的更改"
              },
              "revert": {
                "description": "撤销之前的提交"
              }
            }
        }
    }
// ...
}

注意:默认当前版本已经集成了 config.commitizen.types 的中文描述,如果你不喜欢默认的中文描述,可通过上述配置自定义修改。

环境变量

以下环境变量可用于覆盖任何默认配置或基于 package.json 的配置。

  • CZ_TYPE = 默认类型
  • CZ_SCOPE = 默认范围
  • CZ_SUBJECT = 默认简要描述
  • CZ_BODY = 默认正文
  • CZ_MAX_HEADER_WIDTH = 标题最大长度
  • CZ_MAX_LINE_WIDTH = 行最大长度

Commitizen

初始化项目以使用 cz-conventional-changelog-zh-cn 适配器,更多内容请参考 commitizen 主页。


# npm
commitizen init cz-conventional-changelog-zh-cn --save-dev --save-exact

# yarn
commitizen init cz-conventional-changelog-zh-cn --yarn --dev --exact

# pnpm
commitizen init cz-conventional-changelog-zh-cn --pnpm --save-dev --save-exact

更多提交类型的说明请参考 conventional-changelog 提交类型

Commitlint

如果使用 commitlint JavaScript 库,maxHeaderWidth 配置属性将默认使用 header-max-length 规则的配置值,而不是硬编码的默认值 100。这可以通过在 package.json 中设置 maxHeaderWidth 配置或者设置 CZ_MAX_HEADER_WIDTH 环境变量来进行覆盖。