Skip to content

Commit

Permalink
refactor: gitignore解除忽略.vscode目录,便于统一开发环境
Browse files Browse the repository at this point in the history
  • Loading branch information
simply-none committed Mar 31, 2024
1 parent 1b4ee7f commit 36fa03e
Show file tree
Hide file tree
Showing 4 changed files with 230 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
.DS_Store
.vscode
.history
node_modules
cache
Expand Down
56 changes: 56 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
{
"recommendations": [
"aaron-bond.better-comments",
"adpyke.codesnap",
"alefragnani.Bookmarks",
"antfu.goto-alias",
"antfu.iconify",
"antfu.unocss",
"bierner.markdown-mermaid",
"cweijan.vscode-office",
"DavidAnson.vscode-markdownlint",
"dbaeumer.vscode-eslint",
"EditorConfig.EditorConfig",
"esbenp.prettier-vscode",
"formulahendry.auto-close-tag",
"formulahendry.auto-rename-tag",
"Gruntfuggly.todo-tree",
"heybourn.headwind",
"hollowtree.vue-snippets",
"HookyQR.minify",
"huizhou.githd",
"jeff-hykin.polacode-2019",
"jsynowiec.vscode-insertdatestring",
"lokalise.i18n-ally",
"mdickin.markdown-shortcuts",
"mhutchie.git-graph",
"mikestead.dotenv",
"mrmlnc.vscode-duplicate",
"mrmlnc.vscode-less",
"MS-CEINTL.vscode-language-pack-zh-hans",
"ms-vscode.js-debug-nightly",
"ms-vscode.vscode-typescript-next",
"OBKoro1.korofileheader",
"octref.vetur",
"PKief.material-icon-theme",
"redjue.git-commit-plugin",
"ritwickdey.LiveServer",
"rohinivsenthil.postcode",
"sdras.vue-vscode-snippets",
"shd101wyy.markdown-preview-enhanced",
"SS.element-ui-snippets",
"starkwang.markdown",
"steoates.autoimport",
"streetsidesoftware.code-spell-checker",
"stylelint.vscode-stylelint",
"uctakeoff.vscode-counter",
"usernamehw.errorlens",
"UvDream.git-commit-lint-vscode",
"Vue.volar",
"waderyan.gitblame",
"wejectchan.vue3-snippets-for-vscode",
"yandeu.five-server",
"yzhang.markdown-all-in-one",
"zhucy.project-tree",
]
}
48 changes: 48 additions & 0 deletions .vscode/global.code-snippets
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
// Place your latest-blogs workspace snippets here. Each snippet is defined under a snippet name and has a scope, prefix, body and
// description. Add comma separated ids of the languages where the snippet is applicable in the scope field. If scope
// is left empty or omitted, the snippet gets applied to all languages. The prefix is what is
// used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders.
// Placeholders with the same ids are connected.
// Example:
// "Print to console": {
// "scope": "javascript,typescript",
// "prefix": "log",
// "body": [
// "console.log('$1');",
// "$2"
// ],
// "description": "Log output to console"
// }
"javascript-md": {
"prefix": "dj",
"body": [
"",
"```javascript",
"",
"",
"```",
"",
""
],
"description": "javascript-md"
},
"代码组": {
"prefix": "dg",
"body": [
"",
"::: code-group",
"",
"```javascript [name]",
"",
"",
"```",
"",
":::",
"",
""
],
"description": "代码组"
}
}
126 changes: 126 additions & 0 deletions .vscode/setting.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
{
"explorer.confirmDelete": false,
"files.autoSave": "afterDelay",
"security.workspace.trust.untrustedFiles": "open",
"terminal.integrated.profiles.windows": {
"PowerShell": {
"source": "PowerShell",
"icon": "terminal-powershell"
},
"Command Prompt": {
"path": [
"${env:windir}\\Sysnative\\cmd.exe",
"${env:windir}\\System32\\cmd.exe"
],
"args": [],
"icon": "terminal-cmd"
},
"Git": {
"source": "Git Bash",
"path": "Z:\\apps\\Git\\bin\\bash.exe",
"args": []
}
},
"terminal.integrated.defaultProfile.osx": "",
"editor.mouseWheelZoom": true,
"editor.accessibilitySupport": "off",
"diffEditor.wordWrap": "on",
"editor.wordWrap": "on",
"terminal.integrated.defaultProfile.windows": "Command Prompt",
"[markdown]": {
"editor.quickSuggestions": {
"other": true,
"comments": true,
"strings": true
},
"editor.acceptSuggestionOnEnter": "on",
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"explorer.confirmDragAndDrop": false,
"[javascript]": {
"editor.defaultFormatter": "vscode.typescript-language-features"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"files.autoSaveDelay": 100,
"[typescript]": {
"editor.defaultFormatter": "vscode.typescript-language-features"
},
"workbench.colorTheme": "Default Light+",
"terminal.integrated.automationProfile.linux": {},
"editor.tabSize": 2,
"javascript.suggest.completeJSDocs": false,
"git.enableSmartCommit": true,
"git.confirmSync": false,
"workbench.iconTheme": "material-icon-theme",
"window.commandCenter": true,
"[vue]": {
"editor.defaultFormatter": "Vue.volar"
},
"liveServer.settings.donotShowInfoMsg": true,
"editor.unicodeHighlight.ambiguousCharacters": false,
"[html]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"editor.unicodeHighlight.invisibleCharacters": false,
"update.enableWindowsBackgroundUpdates": false,
"update.mode": "none",
"update.showReleaseNotes": false,
"workbench.editor.enablePreview": false,
"workbench.editorAssociations": {
"*.md": "default"
},
"vue.splitEditors.layout.left": [
"script",
"scriptSetup",
"styles"
],
"Notes.notesLocation": "z:\\笔记\\latest-blogs",
// 头部注释
"fileheader.configObj": {
"supportAutoLanguage": ["vue", "ts", "js", "mjs", "cjs"],
"autoAddLine": 20, // 默认文件超过100行就不再自动添加头部注释
"functionWideNum": 10,
"createHeader": true,
"createFileTime": true
},
// 函数注释
"fileheader.cursorMode": {
"description": "", // 函数注释生成之后,光标移动到这里
"param": "", // param 开启函数参数自动提取 需要将光标放在函数行或者函数上方的空白行
"return": ""
},
"fileheader.customMade": {
// Author字段是文件的创建者 可以在specialOptions中更改特殊属性
// 公司项目和个人项目可以配置不同的用户名与邮箱 搜索: gitconfig includeIf 比如: https://ayase.moe/2021/03/09/customized-git-config/
// 自动提取当前git config中的: 用户名、邮箱
"Author": "git config user.name && git config user.email", // 同时获取用户名与邮箱
// "Author": "git config user.name", // 仅获取用户名
// "Author": "git config user.email", // 仅获取邮箱
// "Author": "OBKoro1", // 写死的固定值 不从git config中获取
"Date": "Do not edit", // 文件创建时间(不变)
// LastEditors、LastEditTime、FilePath将会自动更新 如果觉得时间更新的太频繁可以使用throttleTime(默认为1分钟)配置更改更新时间。
"LastEditors": "git config user.name && git config user.email", // 文件最后编辑者 与Author字段一致
// 由于编辑文件就会变更最后编辑时间,多人协作中合并的时候会导致merge
// 可以将时间颗粒度改为周、或者月,这样冲突就减少很多。搜索变更时间格式: dateFormat
"LastEditTime": "Do not edit", // 文件最后编辑时间
// 输出相对路径,类似: /文件夹名称/src/index.js
"FilePath": "Do not edit", // 文件在项目中的相对路径 自动更新
// 插件会自动将光标移动到Description选项中 方便输入 Description字段可以在specialOptions更改
"Description": "", // 介绍文件的作用、文件的入参、出参。
// custom_string_obkoro1~custom_string_obkoro100都可以输出自定义信息
// 可以设置多条自定义信息 设置个性签名、留下QQ、微信联系方式、输入空行等
"custom_string_obkoro1": "",
// 版权声明 保留文件所有权利 自动替换年份 获取git配置的用户名和邮箱
// 版权声明获取git配置, 与Author字段一致: ${git_name} ${git_email} ${git_name_email},这里获取没有,还得是上面的格式
"custom_string_obkoro1_copyright": "Copyright (c) ${now_year} by git config user.name, All Rights Reserved. "
// "custom_string_obkoro1_copyright": "Copyright (c) ${now_year} by 写死的公司名/用户名, All Rights Reserved. "
},
"[jsonc]": {
"editor.defaultFormatter": "vscode.json-language-features"
},
"files.associations": {
"*.json": "jsonc"
}
}

0 comments on commit 36fa03e

Please sign in to comment.