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

vue-cli-plugin-commitlint-release

v1.1.4

Published

这是一个集成了 commitizen、commitlint、standard-version、conventional-changelog 、conventional-changelog-cli 基础配置的 Vue CLI 插件。

Downloads

169

Readme

Vue CLI Plugin Commitlint Release

这是一个集成了 commitizencommitlintstandard-versionconventional-changelogconventional-changelog-cli 基础配置的 Vue CLI 插件。

NPM version Downloads License

它可以解决以下几个问题:

  1. 自动化提示 commit message
  2. 自动化校验 commit message 是否符合规范
  3. 自动更新 package.json 里的版本号
  4. 自动生成 changelog,更好的维护版本迭代

commitizen 使用的适配器是 AngularJS's commit message convention

安装

作为一个 Vue CLI 插件,安装方法有2种:

# 为了防止和已有的包冲突,可以提前移除 `node_modules` 后再安装
rm -rf node_modules

vue add commitlint-release
# or
vue invoke commitlint-release

这时候你的项目里就会增加一个 commitlint.config.js 文件、release.sh 文件,以及 package.json 里增加一些 scriptsdevDependencies,以及一个 confighusky 的配置。

下面只需要直接运行

npm install

即可将所需依赖安装上。

使用

修改代码后,按照以下步骤执行即可。

add

git add .

自动化 commit message

npm run commit
# or
# 如果你的 NPM 5.2+,也可以执行以下命令
npx git-cz

自动更新版本号并生成 changelog

npm run push

输入命令后,提示输入 [ major | minor | patch ],以当前版本 1.0.0 为例:

  • major:主版本号,当你做了不兼容的 API 修改。这时候的 version 应该为 2.0.0。
  • minor:次版本号,当你做了向下兼容的功能性新增。这时候的 version 应该为 1.1.0。
  • patch:修订号,当你做了向下兼容的问题修正。这时候的 version 应该为 1.0.1。

具体参考:semver 语义化版本控制规范

常见问题

command not found: vue

解决办法:全局安装 vue cli

npm install -g @vue/cli
# or
yarn global add @vue/cli

File exists

npm ERR! path /Users/jojo/node_modules/babel-eslint/node_modules/@babel/traverse/node_modules/.bin/babylon

npm ERR! code EEXIST

npm ERR! Refusing to delete /Users/jojo/wanba/front-activity/node_modules/babel-eslint/node_modules/@babel/traverse/node_modules/.bin/babylon: containing path /Users/jojo/node_modules/babel-eslint/node_modules/@babel/traverse/node_modules/babylon isn't under npm's control

npm ERR! File exists: /Users/jojo/wanba/front-activity/node_modules/babel-eslint/node_modules/@babel/traverse/node_modules/.bin/babylon

npm ERR! Move it away, and try again.

解决办法: 删除 node_modules 重新安装

rm -rf node_modules
npm install

permission denied

EACCES: permission denied

权限问题,命令行前加 sudo 或查看 fixing npm permissions 寻求帮助

Tips

我会尽我最大努力来维护这个项目,所以有问题一定要给我提 issues 哟~

License

ISC