当我尝试更改分支时出现此错误.
我可能会给出一些命令的信息
/path/to/git/repo/.
Run Code Online (Sandbox Code Playgroud)
根据命令:
git branch
Run Code Online (Sandbox Code Playgroud)
我得到以下输出
* V1.5
V2.0
master
Run Code Online (Sandbox Code Playgroud)
当我尝试命令时
git checkout V2.0
Run Code Online (Sandbox Code Playgroud)
我得到以下输出:
fatal: This operation must be run in a work tree
Run Code Online (Sandbox Code Playgroud)
配置文件内容:
cat config
[core]
repositoryformatversion = 0
filemode = true
bare = true
[remote "origin"]
url = /path/to/git/repo/.git
Run Code Online (Sandbox Code Playgroud) 我使用以下代码来检查哈希是否为空.有更好的方法,这是否安全使用?
if (!keys %hash) { print "Empty";}
Run Code Online (Sandbox Code Playgroud) 通过以下命令,我可以找到最大的目录.
find <directory> -printf '%s %p\n' |sort -nr | head
Run Code Online (Sandbox Code Playgroud)
但有没有办法在目录中的所有子目录中找到最大的文件?