mirror of
https://github.com/vbenjs/gf-vben-admin.git
synced 2025-02-02 19:08:40 +08:00
chore: add .github and .vscode
This commit is contained in:
parent
118db6be0a
commit
ad36886559
39
.github/ISSUE_TEMPLATE/1-bug.md
vendored
Normal file
39
.github/ISSUE_TEMPLATE/1-bug.md
vendored
Normal file
@ -0,0 +1,39 @@
|
||||
---
|
||||
name: 🐛 Bug report
|
||||
about: Create a report to help us improve
|
||||
labels: 🔍 status/open, 🐛 type/bug
|
||||
---
|
||||
|
||||
<!--
|
||||
Ouch, sorry you’ve run into a bug. Thank for taking the time to report it!
|
||||
|
||||
Please fill in as much of the template below as you’re able.
|
||||
|
||||
P.S. have you seen our support and contributing docs?
|
||||
https://github.com/get-alex/.github/blob/master/support.md
|
||||
https://github.com/get-alex/.github/blob/master/contributing.md
|
||||
-->
|
||||
|
||||
### Subject of the issue
|
||||
|
||||
Describe your issue here.
|
||||
|
||||
### Your environment
|
||||
|
||||
- **OS**: <!-- Name and version of operating system -->
|
||||
- **Packages**: <!-- Names and version of required packages -->
|
||||
- **Env**: <!-- Version of node, npm, yarn, or names and versions of browser -->
|
||||
|
||||
### Steps to reproduce
|
||||
|
||||
Tell us how to reproduce this issue. Please provide a working and simplified example.
|
||||
|
||||
🎉 BONUS POINTS for creating a [minimal reproduction](https://stackoverflow.com/help/mcve) and uploading it to GitHub. This will get you the fastest support. 🎉
|
||||
|
||||
### Expected behaviour
|
||||
|
||||
What should happen?
|
||||
|
||||
### Actual behaviour
|
||||
|
||||
What happens instead?
|
28
.github/ISSUE_TEMPLATE/2-feature.md
vendored
Normal file
28
.github/ISSUE_TEMPLATE/2-feature.md
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
---
|
||||
name: 🚀 Feature request
|
||||
about: Suggest an idea for this project
|
||||
labels: 🔍 status/open, 🦋 type/enhancement
|
||||
---
|
||||
|
||||
<!--
|
||||
Thank you for suggesting an idea to make this project better!
|
||||
|
||||
Please fill in as much of the template below as you’re able.
|
||||
|
||||
-->
|
||||
|
||||
### Subject of the feature
|
||||
|
||||
Describe your issue here.
|
||||
|
||||
### Problem
|
||||
|
||||
If the feature requests relates to a problem, please describe the problem you are trying to solve here.
|
||||
|
||||
### Expected behaviour
|
||||
|
||||
What should happen? Please describe the desired behaviour.
|
||||
|
||||
### Alternatives
|
||||
|
||||
What are the alternative solutions? Please describe what else you have considered?
|
15
.github/ISSUE_TEMPLATE/3-help.md
vendored
Normal file
15
.github/ISSUE_TEMPLATE/3-help.md
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
---
|
||||
name: Question 🤔
|
||||
about: Usage question or discussion about alex.
|
||||
labels: 🔍 status/open, 🙋 type/question
|
||||
---
|
||||
|
||||
<!--
|
||||
To make it easier for us to help you, please include as much useful information
|
||||
as possible.
|
||||
|
||||
Before opening a new issue, please search existing issues:
|
||||
https://github.com/search?q=org%3Aget-alex&type=Issues
|
||||
|
||||
|
||||
-->
|
89
.github/commit-convention.md
vendored
Normal file
89
.github/commit-convention.md
vendored
Normal file
@ -0,0 +1,89 @@
|
||||
## Git Commit Message Convention
|
||||
|
||||
> This is adapted from [Angular's commit convention](https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-changelog-angular).
|
||||
|
||||
#### TL;DR:
|
||||
|
||||
Messages must be matched by the following regex:
|
||||
|
||||
```js
|
||||
/^(revert: )?(feat|fix|docs|style|refactor|perf|test|workflow|build|ci|chore|types|wip): .{1,50}/;
|
||||
```
|
||||
|
||||
#### Examples
|
||||
|
||||
Appears under "Features" header, `dev` subheader:
|
||||
|
||||
```
|
||||
feat(dev): add 'comments' option
|
||||
```
|
||||
|
||||
Appears under "Bug Fixes" header, `dev` subheader, with a link to issue #28:
|
||||
|
||||
```
|
||||
fix(dev): fix dev error
|
||||
|
||||
close #28
|
||||
```
|
||||
|
||||
Appears under "Performance Improvements" header, and under "Breaking Changes" with the breaking change explanation:
|
||||
|
||||
```
|
||||
perf(build): remove 'foo' option
|
||||
|
||||
BREAKING CHANGE: The 'foo' option has been removed.
|
||||
```
|
||||
|
||||
The following commit and commit `667ecc1` do not appear in the changelog if they are under the same release. If not, the revert commit appears under the "Reverts" header.
|
||||
|
||||
```
|
||||
revert: feat(compiler): add 'comments' option
|
||||
|
||||
This reverts commit 667ecc1654a317a13331b17617d973392f415f02.
|
||||
```
|
||||
|
||||
### Full Message Format
|
||||
|
||||
A commit message consists of a **header**, **body** and **footer**. The header has a **type**, **scope** and **subject**:
|
||||
|
||||
```
|
||||
<type>(<scope>): <subject>
|
||||
<BLANK LINE>
|
||||
<body>
|
||||
<BLANK LINE>
|
||||
<footer>
|
||||
```
|
||||
|
||||
The **header** is mandatory and the **scope** of the header is optional.
|
||||
|
||||
### Revert
|
||||
|
||||
If the commit reverts a previous commit, it should begin with `revert: `, followed by the header of the reverted commit. In the body, it should say: `This reverts commit <hash>.`, where the hash is the SHA of the commit being reverted.
|
||||
|
||||
### Type
|
||||
|
||||
If the prefix is `feat`, `fix` or `perf`, it will appear in the changelog. However, if there is any [BREAKING CHANGE](#footer), the commit will always appear in the changelog.
|
||||
|
||||
Other prefixes are up to your discretion. Suggested prefixes are `docs`, `chore`, `style`, `refactor`, and `test` for non-changelog related tasks.
|
||||
|
||||
### Scope
|
||||
|
||||
The scope could be anything specifying the place of the commit change. For example `dev`, `build`, `workflow`, `cli` etc...
|
||||
|
||||
### Subject
|
||||
|
||||
The subject contains a succinct description of the change:
|
||||
|
||||
- use the imperative, present tense: "change" not "changed" nor "changes"
|
||||
- don't capitalize the first letter
|
||||
- no dot (.) at the end
|
||||
|
||||
### Body
|
||||
|
||||
Just as in the **subject**, use the imperative, present tense: "change" not "changed" nor "changes". The body should include the motivation for the change and contrast this with previous behavior.
|
||||
|
||||
### Footer
|
||||
|
||||
The footer should contain any information about **Breaking Changes** and is also the place to reference GitHub issues that this commit **Closes**.
|
||||
|
||||
**Breaking Changes** should start with the word `BREAKING CHANGE:` with a space or two newlines. The rest of the commit message is then used for this.
|
5
.github/contributing.md
vendored
Normal file
5
.github/contributing.md
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
# Contributing Guide
|
||||
|
||||
1. Make sure you put things in the right category!
|
||||
2. Always add your items to the end of a list. To be fair, the order is first-come-first-serve.
|
||||
3. If you think something belongs in the wrong category, or think there needs to be a new category, feel free to edit things too.
|
34
.github/pull_request_template.md
vendored
Normal file
34
.github/pull_request_template.md
vendored
Normal file
@ -0,0 +1,34 @@
|
||||
### `General`
|
||||
|
||||
> ✏️ Mark the necessary items without changing the structure of the PR template.
|
||||
|
||||
- [ ] Pull request template structure not broken
|
||||
|
||||
### `Type`
|
||||
|
||||
> ℹ️ What types of changes does your code introduce?
|
||||
|
||||
> 👉 _Put an `x` in the boxes that apply_
|
||||
|
||||
- [ ] Bug fix (non-breaking change which fixes an issue)
|
||||
- [ ] New feature (non-breaking change which adds functionality)
|
||||
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
|
||||
- [ ] This change requires a documentation update
|
||||
|
||||
### `Checklist`
|
||||
|
||||
> ℹ️ Check all checkboxes - this will indicate that you have done everything in accordance with the rules in [CONTRIBUTING](https://github.com/vuejs/awesome-vue/blob/master/.github/contributing.md).
|
||||
|
||||
> 👉 _Put an `x` in the boxes that apply._
|
||||
|
||||
- [ ] My code follows the style guidelines of this project
|
||||
- [ ] Is the code format correct
|
||||
- [ ] Is the git submission information standard?
|
||||
- [ ] My code follows the style guidelines of this project
|
||||
- [ ] I have performed a self-review of my own code
|
||||
- [ ] I have commented my code, particularly in hard-to-understand areas
|
||||
- [ ] I have made corresponding changes to the documentation
|
||||
- [ ] My changes generate no new warnings
|
||||
- [ ] I have added tests that prove my fix is effective or that my feature works
|
||||
- [ ] New and existing unit tests pass locally with my changes
|
||||
- [ ] Any dependent changes have been merged and published in downstream modules
|
12
.vscode/extensions.json
vendored
Normal file
12
.vscode/extensions.json
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"recommendations": [
|
||||
"octref.vetur",
|
||||
"dariofuzinato.vue-peek",
|
||||
"dbaeumer.vscode-eslint",
|
||||
"stylelint.vscode-stylelint",
|
||||
"DavidAnson.vscode-markdownlint",
|
||||
"esbenp.prettier-vscode",
|
||||
"mrmlnc.vscode-scss",
|
||||
"Orta.vscode-jest"
|
||||
]
|
||||
}
|
48
.vscode/launch.json
vendored
Normal file
48
.vscode/launch.json
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
{
|
||||
"version": "0.2.0",
|
||||
"configurations": [
|
||||
// node环境调试当前激活编辑器ts/js代码
|
||||
{
|
||||
"type": "node",
|
||||
"request": "launch",
|
||||
"name": "file",
|
||||
"cwd": "${workspaceFolder}",
|
||||
"program": "${file}",
|
||||
// .vscode 目录又不认识了???
|
||||
"preLaunchTask": "tsc: 监视 - build/tsconfig.json", // cn
|
||||
// "preLaunchTask": "tsc: watch - build/tsconfig.json", // en
|
||||
"outFiles": ["${workspaceFolder}/compile/**/*.js"]
|
||||
// "args": ["--experimental-modules", "--loader", "./loader.mjs"]
|
||||
},
|
||||
// 调试开发环境脚本
|
||||
{
|
||||
"type": "node",
|
||||
"request": "launch",
|
||||
"name": "dev",
|
||||
// "stopOnEntry": true,
|
||||
"cwd": "${workspaceFolder}",
|
||||
"program": "${workspaceFolder}/node_modules/@vue/cli-service/bin/vue-cli-service.js",
|
||||
"args": ["serve", "--open"]
|
||||
},
|
||||
// 调试生产环境脚本
|
||||
{
|
||||
"type": "node",
|
||||
"request": "launch",
|
||||
"name": "build",
|
||||
// "stopOnEntry": true,
|
||||
"cwd": "${workspaceFolder}",
|
||||
"program": "${workspaceFolder}/node_modules/@vue/cli-service/bin/vue-cli-service.js",
|
||||
"args": ["build"]
|
||||
},
|
||||
// 调试单元测试脚本
|
||||
{
|
||||
"type": "node",
|
||||
"request": "launch",
|
||||
"name": "test:unit",
|
||||
// "stopOnEntry": true,
|
||||
"cwd": "${workspaceFolder}",
|
||||
"program": "${workspaceFolder}/node_modules/@vue/cli-service/bin/vue-cli-service.js",
|
||||
"args": ["test:unit", "--detectOpenHandles"]
|
||||
}
|
||||
]
|
||||
}
|
251
.vscode/settings.json
vendored
Normal file
251
.vscode/settings.json
vendored
Normal file
@ -0,0 +1,251 @@
|
||||
{
|
||||
"typescript.tsdk": "./node_modules/typescript/lib",
|
||||
//===========================================
|
||||
//============= Editor ======================
|
||||
//===========================================
|
||||
"explorer.openEditors.visible": 0,
|
||||
"editor.minimap.renderCharacters": false,
|
||||
"editor.minimap.maxColumn": 300,
|
||||
"editor.minimap.showSlider": "always",
|
||||
"editor.smoothScrolling": true,
|
||||
"editor.cursorBlinking": "phase",
|
||||
"editor.cursorSmoothCaretAnimation": true,
|
||||
"editor.detectIndentation": false, // vscode默认启用了根据文件类型自动设置tabsize的选项
|
||||
"diffEditor.ignoreTrimWhitespace": false,
|
||||
"editor.formatOnPaste": true, //自动格式化粘贴的内容
|
||||
"editor.formatOnSave": true, //保存自动格式化
|
||||
"editor.suggestSelection": "first",
|
||||
"editor.trimAutoWhitespace": true,
|
||||
"editor.quickSuggestions": {
|
||||
// 快速提示
|
||||
"other": true,
|
||||
"comments": true,
|
||||
"strings": true
|
||||
},
|
||||
//===========================================
|
||||
//============= Other =======================
|
||||
//===========================================
|
||||
"breadcrumbs.enabled": true, // 启用/禁用导航路径
|
||||
"open-in-browser.default": "chrome", // 默认浏览器
|
||||
//===========================================
|
||||
//============= emmet =======================
|
||||
//===========================================
|
||||
"emmet.triggerExpansionOnTab": true, // 配置emmet是否启用tab展开缩写
|
||||
"emmet.showAbbreviationSuggestions": true,
|
||||
"emmet.showExpandedAbbreviation": "always",
|
||||
"emmet.syntaxProfiles": {
|
||||
// 配置emmet对文件类型的支持,比如vue后缀文件按照html文件来进行emmet扩写
|
||||
"vue-html": "html",
|
||||
"vue": "html",
|
||||
"javascript": "javascriptreact",
|
||||
// xml类型文件默认都是单引号,开启对非单引号的emmet识别
|
||||
"xml": {
|
||||
"attr_quotes": "single"
|
||||
}
|
||||
},
|
||||
"emmet.includeLanguages": {
|
||||
// 在react的jsx中添加对emmet的支持
|
||||
"jsx-sublime-babel-tags": "javascriptreact"
|
||||
},
|
||||
//===========================================
|
||||
//============= files =======================
|
||||
//===========================================
|
||||
// "files.autoSave": "onWindowChange", // 窗口失去焦点自动保存
|
||||
// "files.autoSaveDelay": 1000, // 自动保存时间
|
||||
"files.trimTrailingWhitespace": true, // 启用后,将在保存文件时剪裁尾随空格。
|
||||
// 文件末尾插入新行
|
||||
"files.insertFinalNewline": true,
|
||||
// 删除文件末尾多余的新行
|
||||
"files.trimFinalNewlines": true,
|
||||
"files.eol": "\n",
|
||||
"search.exclude": {
|
||||
// 搜索排除这些区域
|
||||
"**/node_modules": true,
|
||||
"**/*.log": true,
|
||||
"**/*.log*": true,
|
||||
"**/bower_components": true,
|
||||
"**/dist": true,
|
||||
"**/elehukouben": true,
|
||||
"**/.git": true,
|
||||
"**/.gitignore": true,
|
||||
"**/.svn": true,
|
||||
"**/.DS_Store": true,
|
||||
"**/.idea": true,
|
||||
"**/.vscode": false,
|
||||
"**/yarn.lock": true,
|
||||
"**/tmp": true
|
||||
},
|
||||
"files.exclude": {
|
||||
// 排除文件搜索区域,比如node_modules(默认设置已经屏蔽了)
|
||||
// "**/node_modules": true,
|
||||
"**/bower_components": true,
|
||||
"**/.idea": true,
|
||||
"**/yarn.lock": true,
|
||||
"**/tmp": true,
|
||||
"**/.git": true,
|
||||
"**/.svn": true,
|
||||
"**/.hg": true,
|
||||
"**/CVS": true,
|
||||
"**/.DS_Store": true
|
||||
},
|
||||
"files.watcherExclude": {
|
||||
// 文件监视排除
|
||||
"**/.git/objects/**": true,
|
||||
"**/.git/subtree-cache/**": true,
|
||||
"**/.vscode/**": true,
|
||||
"**/node_modules/**": true,
|
||||
"**/tmp/**": true,
|
||||
"**/bower_components/**": true,
|
||||
"**/dist/**": true,
|
||||
"**/yarn.lock": true
|
||||
},
|
||||
"files.associations": {
|
||||
// 配置文件关联,以便启用对应的智能提示,比如wxss使用css
|
||||
"*.vue": "vue",
|
||||
"*.wxss": "css"
|
||||
},
|
||||
"stylelint.enable": true,
|
||||
"stylelint.packageManager": "yarn",
|
||||
"css.validate": true,
|
||||
"less.validate": true,
|
||||
"scss.validate": true,
|
||||
// ↓↓↓↓↓↓↓↓↓↓↓↓↓ 以下为插件设置 ↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓
|
||||
// ↓↓↓↓↓↓↓↓↓↓↓↓↓ 需要安装对应的插件 ↓↓↓↓↓↓↓↓↓↓↓↓
|
||||
// ↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓
|
||||
// ===========================================
|
||||
// ================ Eslint ===================
|
||||
// ===========================================
|
||||
"eslint.enable": true, // 是否开启eslint
|
||||
|
||||
"eslint.options": {
|
||||
// 配置
|
||||
"plugins": ["html", "vue", "javascript", "jsx", "typescript"]
|
||||
},
|
||||
"eslint.autoFixOnSave": true, // 保存自动格式化
|
||||
// ===========================================
|
||||
// ================ Vetur ====================
|
||||
// ===========================================
|
||||
"vetur.format.options.tabSize": 2,
|
||||
"vetur.format.defaultFormatter.html": "js-beautify-html", // 使用js-beautify-html格式化
|
||||
"vetur.format.defaultFormatter.scss": "prettier", // 使用js-beautify-html格式化
|
||||
"vetur.format.defaultFormatter.css": "prettier", // 使用js-beautify-html格式化
|
||||
// "vetur.format.defaultFormatter.html": "prettyhtml",
|
||||
"vetur.format.defaultFormatter.js": "prettier",
|
||||
// "vetur.useWorkspaceDependencies": true,
|
||||
"vetur.format.defaultFormatterOptions": {
|
||||
"js-beautify-html": {
|
||||
// "wrap_attributes": "force-aligned", // 单行
|
||||
"wrap_attributes": "force-expand-multiline" // 属性强制折行对齐 多行
|
||||
},
|
||||
"prettier": {
|
||||
"eslintIntegration": true, // 让perttier使用eslint的格式进行检查
|
||||
"arrowParens": "always", // 箭头函数参数括号 默认avoid 可选 avoid | always
|
||||
"semi": false, // 使用分号, 默认true
|
||||
"singleQuote": true // 使用单引号, 默认false(在jsx中配置无效, 默认都是双引号)
|
||||
}
|
||||
},
|
||||
// ===========================================
|
||||
// ============= Material Icon Theme =========
|
||||
// ===========================================
|
||||
"workbench.iconTheme": "material-icon-theme", // 主题色
|
||||
// ===========================================
|
||||
// ============= stylus Supremacy ============
|
||||
// ===========================================
|
||||
"stylusSupremacy.insertColons": false, // 是否插入冒号
|
||||
"stylusSupremacy.insertSemicolons": false, // 是否插入分号
|
||||
"stylusSupremacy.insertBraces": false, // 是否插入大括号
|
||||
//===========================================
|
||||
//============= koroFileHeaders ===============
|
||||
//===========================================
|
||||
"fileheader.configObj": {
|
||||
"autoAdd": false // 将该选项设置为true即可开启
|
||||
},
|
||||
// 函数注释
|
||||
//===========================================
|
||||
//============= Code Runner =================
|
||||
//===========================================
|
||||
"javascript.updateImportsOnFileMove.enabled": "never",
|
||||
"liveServer.settings.donotShowInfoMsg": true,
|
||||
"[javascript]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"terminal.integrated.rendererType": "dom", //关闭liveserver提示
|
||||
"telemetry.enableCrashReporter": false,
|
||||
"telemetry.enableTelemetry": false,
|
||||
"workbench.settings.enableNaturalLanguageSearch": false,
|
||||
// 引用路径设置
|
||||
"path-intellisense.mappings": {
|
||||
"/@/": "${workspaceRoot}/src"
|
||||
},
|
||||
"prettier.requireConfig": true,
|
||||
"typescript.updateImportsOnFileMove.enabled": "always",
|
||||
"workbench.sideBar.location": "left",
|
||||
"cSpell.enabledLanguageIds": [
|
||||
"asciidoc",
|
||||
"c",
|
||||
"cpp",
|
||||
"csharp",
|
||||
"css",
|
||||
"git-commit",
|
||||
"go",
|
||||
"handlebars",
|
||||
"haskell",
|
||||
"html",
|
||||
"jade",
|
||||
"java",
|
||||
"javascript",
|
||||
"javascriptreact",
|
||||
"json",
|
||||
"jsonc",
|
||||
"latex",
|
||||
"less",
|
||||
"markdown",
|
||||
"php",
|
||||
"plaintext",
|
||||
"pug",
|
||||
"python",
|
||||
"restructuredtext",
|
||||
"rust",
|
||||
"scala",
|
||||
"scss",
|
||||
"text",
|
||||
"typescript",
|
||||
"typescriptreact",
|
||||
"yaml",
|
||||
"yml"
|
||||
],
|
||||
"[javascriptreact]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[typescript]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[typescriptreact]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[json]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[jsonc]": {
|
||||
"editor.defaultFormatter": "vscode.json-language-features"
|
||||
},
|
||||
"[html]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[css]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[less]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[scss]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[markdown]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"cSpell.words": ["yfboilerplate"],
|
||||
"editor.codeActionsOnSave": {
|
||||
"source.fixAll.eslint": true
|
||||
}
|
||||
}
|
@ -49,6 +49,7 @@ module.exports = {
|
||||
'revert',
|
||||
'wip',
|
||||
'workflow',
|
||||
'types',
|
||||
],
|
||||
],
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user