I have the git repo and i have two remote repos
one is deafult
and other backup
I push to other branch by
git push backup
Now i have folder called backupfiles
which i don't want to push in deafult
but i do want it to be avaiable in backup
repo
is there any way
You can choose which refs (branches, tags etc) you push to or fetch from another repository, but the files committed in the history of a ref are non-negotiable (unless you change the history with eg git filter-branch
). You could create another branch where you commit the files in the backupfiles
directory and push that branch to a subset of your remote repositories.
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.