Skip to content

Commit

Permalink
feat: 🎸 add auto release log function
Browse files Browse the repository at this point in the history
add auto release log function
  • Loading branch information
lgf-136 committed Sep 27, 2022
1 parent b5b1702 commit 43f32fd
Show file tree
Hide file tree
Showing 5 changed files with 513 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
. "$(dirname -- "$0")/_/husky.sh"

# npm test
# npx --no-install commitlint --edit "$1"
npx commitlint --edit "${1}"
npx --no-install commitlint --edit "$1"
# npx commitlint --edit "${1}"

# npx husky add .husky/commit-msg "npx --no-install commitlint -e $HUSKY_GIT_PARAMS"

Expand Down
12 changes: 12 additions & 0 deletions .versionrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module.exports = {
"types": [
{"type": "feat", "section": "Features"},
{"type": "fix", "section": "Bug Fixes"},
{"type": "chore", "hidden": true},
{"type": "docs", "hidden": true},
{"type": "style", "hidden": true},
{"type": "refactor", "hidden": true},
{"type": "perf", "hidden": true},
{"type": "test", "hidden": true}
]
}
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@ pnpm install -D -w eslint typescript @typescript-eslint/eslint-plugin @typescri

## stylelint

## git-cz + husky + commitlint
## git-cz + husky + commitlint + release log

```
pnpm add -D -w git-cz
pnpm add -D -w @commitlint/cli @commitlint/config-conventional commitlint
pnpm add -D -w husky lint-staged
pnpm add -D -w husky lint-staged standard-version
npx husky add .husky/commit-msg 'npx --no -- commitlint --edit "$1"'
npx husky add .husky/pre-commit "pnpm run lint-staged"
npx husky add .husky/commit-msg 'npx --no-install commitlint --edit "$1"'
npx husky add .husky/pre-commit "npx lint-staged"
```

## 子模块的添加
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"cz": "git-cz",
"eslint": "eslint . --ext .js,.jsx,.ts,.tsx,.vue",
"dev:demo1": "cd projects/vite-project && pnpm install && pnpm dev",
"pull": "git pull && cd .vscode && git pull && cd .. && cd config && git pull && cd .."
"pull": "git pull && cd .vscode && git pull && cd .. && cd config && git pull && cd ..",
"release": "standard-version"
},
"devDependencies": {
"@commitlint/cli": "^17.1.2",
Expand All @@ -29,6 +30,7 @@
"husky": "^8.0.1",
"lint-staged": "^13.0.3",
"react": "^18.2.0",
"standard-version": "^9.5.0",
"typescript": "^4.6.4",
"vite": "^3.1.3",
"vue-eslint-parser": "^9.1.0"
Expand Down
Loading

0 comments on commit 43f32fd

Please sign in to comment.