Spot Git 提交 Mistake
找错误 简单
题目
这个 git 提交 command 有 problem. 什么是 错误?
代码
git commit -m Updated the README file
提示
消息使用空间需要到 是 quoted.
解释
The -m flag expects a commit message as a string. When the message contains spaces, it must be wrapped in quotes. Without quotes, Git interprets only "更新" as the message and tries to treat "", "README", and "file" as file paths, causing an error. The corrected command is: git 提交 -m "更新 README file"
相关资源
相关课程
- Git 提交
学习如何 编写 proper 提交消息.
相关速查表
- Git Cheatsheet
快速引用 for git 提交语法.
查阅不认识的术语
新手友好的术语表用大白话解释编程术语——变量、函数、DOM、Promise 等等。
解读错误信息
用大白话解释常见错误——什么意思、为什么发生、如何修复。
动手做项目
通过引导式项目应用所学,含起始代码与解决方案。