Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
从 github 下载的 zip 的文件夹名称是这样的%repository-name%-master,但我需要那个文件夹%repository-name%
%repository-name%-master
%repository-name%
这可以做到吗?
您不能修改 github 存档中包含的根目录的名称。
即使您下载大师:
wget https://github.com/user/repo/tarball/master
您将获得一个名为“master”的文件,但是:
tar xpvf master
tar xpvf会给你一个repo-xxxx目录。 我通常遵循:
tar xpvf
repo-xxxx
mv repo-* repo