git

git提交规范

feat	✨	引入新功能
fix	    🐛	 修复 bug
style	💄	 更新 UI 样式文按键
format	🥚	 格式化代码
docs	📝	 添加/更新文档
perf	👌	  提高性能/优化
init	🎉	 初次提交/初始化项目
test	✅	增加测试代码
refactor 🎨改进代码结构/代码格式
patch	🚑	添加重要补丁
file	📦	添加新文件
publish	🚀	发布新版本
tag	    📌	发布新版本
config	🔧	修改配置文件
git	   🙈	添加或修改.gitignore 文件
revert       回滚

# 1. 纯 Git 实现前端 CI/CD

https://juejin.cn/post/7012203717818580999/

# 2. 本地配置 ssh(getaddrinfo() thread failed to start 解决方法)

# // 生成 密钥对
ssh-keygen -t rsa -C 'xxx.mail@xxx.com'
# // 设置Git的user name和email:
git config --global user.name "zouyu"
git config --global user.email "zouyu@temp.com"

详情 (opens new window)

# 3. 不设置 git 代理

git config --global --unset http.proxy
git config --global --unset https.proxy

# 4. 跳过 git 提交验证

git commit -m "XXX" --no-verify

Vue3 项目 报错'defineProps' is not defined 的解决方法 https://eslint.vuejs.org/user-guide/#compiler-macros-such-as-defineprops-and-defineemits-generate-no-undef-warnings

# 5. git 不忽略大小写变更跟踪

git config core.ignorecase false

# git 安全验证

gitbash 2.35.2 版本后引入的安全特性

//  全局禁用安全检查
git config --global --add safe.directory '*'
上次更新: