Reference Reference reference

git init

git init 用于把普通目录初始化为 Git 仓库。

语法

text
git init [directory]

最小示例

bash
git init my-project

常见错误

  • 只看语法不看运行环境限制。
  • 没有处理错误、权限或兼容性分支。
  • 示例上线前应结合真实浏览器、服务器或 Git 仓库验证。

相关内容