Skip to content

Commit

Permalink
Merge pull request #46 from kwooshung/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
kwooshung authored Jan 4, 2024
2 parents 03d37a8 + c0bfa4c commit 842620e
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 10 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ Here, **Regenerate Logs** is used as a demonstration, as it consists of two step

```yml
- name: Auto Release
run: cvlar -r
run: npx cvlar -r
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
```
Expand Down Expand Up @@ -333,18 +333,18 @@ The following two files are configuration files generated by this command, repre

## Commitlint Configuration

The file [commitlint.cjs](https://github.com/kwooshung/cvlar/blob/main/commitlint.cjs) is a configuration file for `commitlint`. It is designed for setting up `commitlint`. To simplify unified management, two separate files, `ks-cvlar.types.cjs` and `ks-cvlar.scopes.cjs`, are created. They are used for configuring the `types` and `scopes` in `commitlint` and also for configuring the `commit` menu in `cvlar`.
The file [.commitlintrc.cjs](https://github.com/kwooshung/cvlar/blob/main/.commitlintrc.cjs) is a configuration file for `commitlint`. It is designed for setting up `commitlint`. To simplify unified management, two separate files, `ks-cvlar.types.cjs` and `ks-cvlar.scopes.cjs`, are created. They are used for configuring the `types` and `scopes` in `commitlint` and also for configuring the `commit` menu in `cvlar`.

- [This repository's commit types configuration](https://github.com/kwooshung/cvlar/blob/main/scripts/ks-cvlar.types.cjs)
- [This repository's commit scopes configuration](https://github.com/kwooshung/cvlar/blob/main/scripts/ks-cvlar.scopes.cjs)

In [commitlint.cjs](https://github.com/kwooshung/cvlar/blob/main/commitlint.cjs), you can import the `ks-cvlar.types.cjs` and `ks-cvlar.scopes.cjs` files. However, since the `commit` configuration in `cvlar` differs from that in `commitlint`, you need to import two functions like this:
In [.commitlintrc.cjs](https://github.com/kwooshung/cvlar/blob/main/.commitlintrc.cjs), you can import the `ks-cvlar.types.cjs` and `ks-cvlar.scopes.cjs` files. However, since the `commit` configuration in `cvlar` differs from that in `commitlint`, you need to import two functions like this:

```javascript
const { ConvertToLintTypes, ConvertToLintScopes } = require('@kwooshung/cvlar');
```

This facilitates conversion to commitlint configuration. For detailed usage, please refer to [commitlint.cjs](https://github.com/kwooshung/cvlar/blob/main/commitlint.cjs).
This facilitates conversion to commitlint configuration. For detailed usage, please refer to [.commitlintrc.cjs](https://github.com/kwooshung/cvlar/blob/main/.commitlintrc.cjs).

### When Translating Commit Messages with Commitlint Enabled

Expand Down
8 changes: 4 additions & 4 deletions README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ pnpm add standard-version @kwooshung/cvlar -D

```yml
- name: Auto Release
run: cvlar -r
run: npx cvlar -r
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
```
Expand Down Expand Up @@ -329,19 +329,19 @@ cvlar -[cd/config-dir] xxx/xx/x

## commitlint 配置

此文件 [commitlint.cjs](https://github.com/kwooshung/cvlar/blob/main/commitlint.cjs)`commitlint` 的配置文件,用于 `commitlint` 的配置;
此文件 [.commitlintrc.cjs](https://github.com/kwooshung/cvlar/blob/main/.commitlintrc.cjs)`commitlint` 的配置文件,用于 `commitlint` 的配置;
为了方便统一管理,所以独立出来了 `ks-cvlar.types.cjs``ks-cvlar.scopes.cjs` 两个文件,用于 `commitlint``types``scopes` 的配置,及 `cvlar``commit` 菜单的配置;

- [本仓库的 commit types 配置](https://github.com/kwooshung/cvlar/blob/main/scripts/ks-cvlar.types.cjs)
- [本仓库的 commit scopes 配置](https://github.com/kwooshung/cvlar/blob/main/scripts/ks-cvlar.scopes.cjs)

[commitlint.cjs](https://github.com/kwooshung/cvlar/blob/main/commitlint.cjs) 中,可以引入 `ks-cvlar.types.cjs``ks-cvlar.scopes.cjs` 两个文件,但由于 `cvlar``commit` 配置 和 `commitlint` 不同,所以您需要这样引入两个函数:
[.commitlintrc.cjs](https://github.com/kwooshung/cvlar/blob/main/.commitlintrc.cjs) 中,可以引入 `ks-cvlar.types.cjs``ks-cvlar.scopes.cjs` 两个文件,但由于 `cvlar``commit` 配置 和 `commitlint` 不同,所以您需要这样引入两个函数:

```javascript
const { ConvertToLintTypes, ConvertToLintScopes } = require('@kwooshung/cvlar');
```

方便转换成 `commitlint` 的配置,具体使用方法,请参考 [commitlint.cjs](https://github.com/kwooshung/cvlar/blob/main/commitlint.cjs)
方便转换成 `commitlint` 的配置,具体使用方法,请参考 [.commitlintrc.cjs](https://github.com/kwooshung/cvlar/blob/main/.commitlintrc.cjs)

### commit message 启用翻译

Expand Down
1 change: 1 addition & 0 deletions changelogs/.history
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
1.1.3
1.1.2
1.1.1
1.1.0
Expand Down
5 changes: 5 additions & 0 deletions changelogs/CHANGELOG.en.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## 🎉 1.1.3 `2024-01-04`
### 🐛 Fix
- Modify the path of the .Commitlintrc.cjs. The previous file name was written wrong ([#0fcbd5c](https://github.com/kwooshung/cvlar/commit/0fcbd5c0848c2a1baf3c7a52a9b762d4fe4579b7))
- Modify the historical record file ([#ed39e58](https://github.com/kwooshung/cvlar/commit/ed39e5890ce76b5fdef37949094617963c43381d))

## 🎉 1.1.2 `2024-01-04`
### 🐛 Fix
- Repair the demonstration picture in the document error ([#5fba958](https://github.com/kwooshung/cvlar/commit/5fba958bbd9321e0f40b0570dfc0f3912d576ed8))
Expand Down
5 changes: 5 additions & 0 deletions changelogs/CHANGELOG.zh-cn.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## 🎉 1.1.3 `2024-01-04`
### 🐛 Fix
- 修改.commitlintrc.cjs的路径。以前的文件名是写错误的 ([#0fcbd5c](https://github.com/kwooshung/cvlar/commit/0fcbd5c0848c2a1baf3c7a52a9b762d4fe4579b7))
- 修改历史记录文件 ([#ed39e58](https://github.com/kwooshung/cvlar/commit/ed39e5890ce76b5fdef37949094617963c43381d))

## 🎉 1.1.2 `2024-01-04`
### 🐛 Fix
- 在文档错误中修复演示图片 ([#5fba958](https://github.com/kwooshung/cvlar/commit/5fba958bbd9321e0f40b0570dfc0f3912d576ed8))
Expand Down
5 changes: 5 additions & 0 deletions changelogs/CHANGELOG.zh-tw.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## 🎉 1.1.3 `2024-01-04`
### 🐛 Fix
- 修改.commitlintrc.cjs的路徑。以前的文件名是寫錯誤的 ([#0fcbd5c](https://github.com/kwooshung/cvlar/commit/0fcbd5c0848c2a1baf3c7a52a9b762d4fe4579b7))
- 修改歷史記錄文件 ([#ed39e58](https://github.com/kwooshung/cvlar/commit/ed39e5890ce76b5fdef37949094617963c43381d))

## 🎉 1.1.2 `2024-01-04`
### 🐛 Fix
- 在文檔錯誤中修復演示圖片 ([#5fba958](https://github.com/kwooshung/cvlar/commit/5fba958bbd9321e0f40b0570dfc0f3912d576ed8))
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@kwooshung/cvlar",
"version": "1.1.2",
"version": "1.1.3",
"title": "cvlar",
"description": "`Cvlar` is an open-source tool combining commit conventions, version control, auto-changelogs, and release automation for streamlined Git workflows.",
"private": false,
Expand Down
2 changes: 1 addition & 1 deletion src/utils/version/get/index.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export default '1.1.1';
export default '1.1.2';

0 comments on commit 842620e

Please sign in to comment.