style(custom): 换行符替换lf

This commit is contained in:
2023-10-10 15:20:10 +08:00
parent 5b33290de6
commit 4074cc4623
9 changed files with 6240 additions and 1516 deletions

View File

@@ -1,23 +1,26 @@
module.exports = { module.exports = {
types: [ types: [
{ value: 'feat', name:'feat: 新增功能' }, { value: 'feat', name: 'feat: 新增功能' },
{ value: 'fix', name:'fix: 修复bug' }, { value: 'fix', name: 'fix: 修复bug' },
{ value: 'docs', name:'docs: 文档变更' }, { value: 'docs', name: 'docs: 文档变更' },
{ value: 'style', name:'style: 代码格式(不影响功能,例如空格、分号等格式修正)' }, { value: 'style', name: 'style: 代码格式(不影响功能,例如空格、分号等格式修正)' },
{ value: 'refactor', name:'refactor: 代码重构(不包括 bug 修复、功能新增)' }, { value: 'refactor', name: 'refactor: 代码重构(不包括 bug 修复、功能新增)' },
{ value: 'perf', name:'perf: 性能优化' }, { value: 'perf', name: 'perf: 性能优化' },
{ value: 'test', name:'test: 添加、修改测试用例' }, { value: 'test', name: 'test: 添加、修改测试用例' },
{ value: 'build', name:'build: 构建流程、外部依赖变更(如升级 npm 包、修改 脚手架 配置等)' }, {
{ value: 'ci', name:'ci: 修改 CI 配置、脚本' }, value: 'build',
{ value: 'chore', name:'chore: 构建过程或辅助工具和库的更改(不影响源文件、测试用例)' }, name: 'build: 构建流程、外部依赖变更(如升级 npm 包、修改 脚手架 配置等)',
{ value: 'revert', name:'revert: 回滚 commit' }, },
{ value: 'wip', name:'wip: 开发中' }, { value: 'ci', name: 'ci: 修改 CI 配置、脚本' },
{ value: 'mod', name:'mod: 不确定分类的修改' }, { value: 'chore', name: 'chore: 对构建过程或辅助工具和库的更改(不影响源文件、测试用例)' },
{ value: 'release', name:'release: 发布' }, { value: 'revert', name: 'revert: 回滚 commit' },
{ value: 'wip', name: 'wip: 开发中' },
{ value: 'mod', name: 'mod: 不确定分类的修改' },
{ value: 'release', name: 'release: 发布' },
], ],
scopes: [ scopes: [
['custom', '自定义'], ['custom', '自定义'],
['projects', '项目搭建'], ['projects', '项目搭建'],
['components', '组件相关'], ['components', '组件相关'],
['utils', 'utils 相关'], ['utils', 'utils 相关'],
['styles', '样式相关'], ['styles', '样式相关'],
@@ -26,7 +29,7 @@ module.exports = {
].map(([value, description]) => { ].map(([value, description]) => {
return { return {
value, value,
name: `${value.padEnd(30)} (${description})` name: `${value.padEnd(30)} (${description})`,
} }
}), }),
messages: { messages: {
@@ -37,9 +40,9 @@ module.exports = {
body: '填写更加详细的变更描述(可选)。使用 "|" 换行:', body: '填写更加详细的变更描述(可选)。使用 "|" 换行:',
breaking: '列举非兼容性重大的变更(可选):', breaking: '列举非兼容性重大的变更(可选):',
footer: '列举出所有变更的 Issues Closed可选。 例如: #31, #34', footer: '列举出所有变更的 Issues Closed可选。 例如: #31, #34',
confirmCommit: '确认提交?' confirmCommit: '确认提交?',
}, },
allowBreakingChanges: ['feat', 'fix'], allowBreakingChanges: ['feat', 'fix'],
subjectLimit: 100, subjectLimit: 100,
breaklineChar: '|' breaklineChar: '|',
} }

15
.idea/git_toolbox_prj.xml generated Normal file
View File

@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="GitToolBoxProjectSettings">
<option name="commitMessageIssueKeyValidationOverride">
<BoolValueOverride>
<option name="enabled" value="true" />
</BoolValueOverride>
</option>
<option name="commitMessageValidationEnabledOverride">
<BoolValueOverride>
<option name="enabled" value="true" />
</BoolValueOverride>
</option>
</component>
</project>

View File

@@ -4,6 +4,6 @@
"antfu.iconify", "antfu.iconify",
"mikestead.dotenv", "mikestead.dotenv",
"sdras.vue-vscode-snippets", "sdras.vue-vscode-snippets",
"cipchk.cssrem", "cipchk.cssrem"
] ]
} }

View File

@@ -41,7 +41,6 @@
[Vue Naive Admin Docs](https://zclzone.github.io/vue-naive-admin-docs) [Vue Naive Admin Docs](https://zclzone.github.io/vue-naive-admin-docs)
### Getting Started ### Getting Started
```shell ```shell
@@ -102,10 +101,10 @@ Vue Naive Admin
|-- build // 构建相关配置 |-- build // 构建相关配置
| |-- constant.js // 构建相关的常量 | |-- constant.js // 构建相关的常量
| |-- utils.js // 构建相关的工具方法 | |-- utils.js // 构建相关的工具方法
| |-- config | |-- config
| | |-- define.js // 注入全局常量启动或打包后将添加到window中 | | |-- define.js // 注入全局常量启动或打包后将添加到window中
| | |-- proxy.js // 代理配置 | | |-- proxy.js // 代理配置
| |-- plugin | |-- plugin
| | |-- html.js // vite-plugin-html插件用于注入变量或者html标签 | | |-- html.js // vite-plugin-html插件用于注入变量或者html标签
| | |-- mock.js // vite-plugin-mock插件处理mock | | |-- mock.js // vite-plugin-mock插件处理mock
| | |-- unplugin.js // unplugin相关插件包含DefineOptions和自动导入 | | |-- unplugin.js // unplugin相关插件包含DefineOptions和自动导入
@@ -155,7 +154,7 @@ Vue Naive Admin
| | |-- demo // 示例 | | |-- demo // 示例
| | |-- error-page // 错误页 | | |-- error-page // 错误页
| | |-- login // 登录页 | | |-- login // 登录页
| | |-- workbench // 首页 | | |-- workbench // 首页
| |-- App.vue | |-- App.vue
| |-- main.js | |-- main.js
|-- .cz-config.js // git提交配置 |-- .cz-config.js // git提交配置
@@ -169,7 +168,7 @@ Vue Naive Admin
|-- .gitignore // git忽略 |-- .gitignore // git忽略
|-- .prettierignore // prettier格式化忽略 |-- .prettierignore // prettier格式化忽略
|-- commitlint.config.js // commitlint规范配置 |-- commitlint.config.js // commitlint规范配置
|-- index.html |-- index.html
|-- jsconfig.json // js配置 |-- jsconfig.json // js配置
|-- LICENSE // 协议 |-- LICENSE // 协议
|-- package.json // 依赖描述文件 |-- package.json // 依赖描述文件
@@ -202,8 +201,3 @@ Vue Naive Admin
<a href="https://blog.qszone.com/about/"> <a href="https://blog.qszone.com/about/">
<img src="https://assets.qszone.com/images/about.png" style="max-width: 400px" /> <img src="https://assets.qszone.com/images/about.png" style="max-width: 400px" />
</a> </a>

View File

@@ -1,3 +1,3 @@
推荐阅读作者在掘金的文章: 推荐阅读作者在掘金的文章:
[保熟的UnoCSS使用指北优雅使用antfu大佬的原子化CSS](https://juejin.cn/post/7142466784971456548) [保熟的 UnoCSS 使用指北,优雅使用 antfu 大佬的原子化 CSS](https://juejin.cn/post/7142466784971456548)

View File

@@ -14,7 +14,7 @@
`<icon-[iconify图标名称]` `<icon-[iconify图标名称]`
```html ```html
<icon-ant-design:fullscreen-exit-outlined /> <icon-ant-design:fullscreen-exit-outlined />
<icon-ant-design:fullscreen-outlined /> <icon-ant-design:fullscreen-outlined />
``` ```
@@ -37,4 +37,4 @@
<TheIcon icon="logo" type="custom" /> <TheIcon icon="logo" type="custom" />
``` ```
封装组件参看 src/components/icon 封装组件参看 src/components/icon

View File

@@ -1,6 +1,6 @@
## 安装pnpm ## 安装 pnpm
### 使用Corepack安装推荐 ### 使用 Corepack 安装(推荐)
从 v16.13 开始Node.js 发布了 Corepack 来管理包管理器。 这是一项实验性功能,需要通过运行如下脚本来启用它: 从 v16.13 开始Node.js 发布了 Corepack 来管理包管理器。 这是一项实验性功能,需要通过运行如下脚本来启用它:
@@ -8,17 +8,19 @@
npx corepack enable // 可能需要管理员权限 npx corepack enable // 可能需要管理员权限
``` ```
这将自动在您的系统上安装 pnpm。 但是,它可能不是最新版本的 pnpm。 若要升级,请检查[最新的 pnpm 版本](https://github.com/pnpm/pnpm/releases/latest) 并运行,如 7.14.0 这将自动在您的系统上安装 pnpm。 但是,它可能不是最新版本的 pnpm。 若要升级,请检查[最新的 pnpm 版本](https://github.com/pnpm/pnpm/releases/latest) 并运行,如 7.14.0
``` ```
corepack prepare pnpm@7.14.0 --activate corepack prepare pnpm@7.14.0 --activate
``` ```
如果是 Node.js v16.17 或者更新的版本,可以直接安装最新版本的 pnpm 如果是 Node.js v16.17 或者更新的版本,可以直接安装最新版本的 pnpm
``` ```
corepack prepare pnpm@latest --activate corepack prepare pnpm@latest --activate
``` ```
### 使用npm安装 ### 使用 npm 安装
``` ```
npm i -g pnpm npm i -g pnpm
@@ -29,4 +31,4 @@ npm i -g pnpm
``` ```
npm uninstall -g pnpm npm uninstall -g pnpm
npm i -g pnpm npm i -g pnpm
``` ```

View File

@@ -11,7 +11,8 @@
"lint:fix": "eslint --fix --ext .js,.vue .", "lint:fix": "eslint --fix --ext .js,.vue .",
"lint:staged": "lint-staged", "lint:staged": "lint-staged",
"prepare": "husky install", "prepare": "husky install",
"preview": "vite preview" "preview": "vite preview",
"lf": "npx prettier --write --end-of-line lf ."
}, },
"lint-staged": { "lint-staged": {
"*.{js,vue}": [ "*.{js,vue}": [

7665
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff