【发布时间】:2016-11-07 02:59:09
【问题描述】:
我已将一个新文件添加到我的本地分支。在运行命令git status 时,它会给出以下输出:
# On branch MyLocBranch
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# mypath/nextDir/myfile.py
nothing added to commit but untracked files present (use "git add" to track)
这很好,因为我有未跟踪的文件,它在终端中显示为红色。
现在为了隐藏这些更改,我运行了命令 git stash 和 git stash save "some message"。但我收到错误No local changes to save,这很奇怪。更改应该已被隐藏。
【问题讨论】:
-
@Matt 谢谢。这就是我要找的东西!
-
因此,您可以将答案标记为已接受的答案,如果您愿意,也可以投票赞成,即使您的问题被标记为重复
标签: git