I have a branch called *master on the local machine
and I have three repositories called:
On this local machine, there is a lot of problems with files, out of sync, etc. the decision has been made to just delete the /site directory and re -clone this from master. I am unsure how to do this.
通常,简单地rm -rf /my/git/repo
然后git clone <wherever I want to clone from> /my/new/git/repo
I think this is what you want -
$ rm -fr /git/site
$ mkdir /git/site && cd /git/site
$ git init
$ git remote add origin git@github.com/org/repo.git
$ git pull origin master
your /git/site
will now be reset to your master branch.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.