开发者

Remove everything

开发者 https://www.devze.com 2022-12-31 23:13 出处:网络
I want to remove everyt开发者_运维知识库hing inside my git project. Is there any easy way to do this?Yeah. Just like you can add everything.

I want to remove everyt开发者_运维知识库hing inside my git project. Is there any easy way to do this?


Yeah. Just like you can add everything.

git rm -r .


Sure:

rm -rf /path/to/gitrepo

Or did you mean 'Remove all files in the project from content tracking'?

git rm -r /path/to/gitrepo
git commit


If you want to completely remove the repo from GitHub, there is "Delete this repository" option for that on the project admin page. The URL is typically something like:

https://github.com/<username>/<project>/edit

If you want to remove the files from the next revision of the repo, but keep their histories, then you should do something like:

git rm -r .

If you only want to eliminate the history of certain files in the repo, you can use git filter-branch.

0

精彩评论

暂无评论...
验证码 换一张
取 消