开发者

can I migrate a bzr central repository trunk to a new location?

开发者 https://www.devze.com 2023-01-19 22:49 出处:网络
I set up an central repository in my home directory. I set it up in my home directory and would lik开发者_JAVA技巧e to move it from /home/$USER to /home/share/.

I set up an central repository in my home directory.

I set it up in my home directory and would lik开发者_JAVA技巧e to move it from /home/$USER to /home/share/.

For reference, here are the details of the initial setup for reference following the directions in the bzr documentation:

#establish the central repository
mkdir project
mkdir project/dev
bzr init-repo --no-trees sftp://server/home/$USER/project
bzr init sftp://server/home/$USER/project/trunk

#make local repository
bzr init-repo project
cd project
bzr branch sftp://server/home/$USER/project/trunk dev

#copy files, add to bzr, commit
mv files project/dev/
bzr add
bzr commit -m 'initial import'


You can move your central repository and all branches inside it with just plain mv command of your system.

But you'll need to update all your local working branches to remember new location after move of central repository. You can do it with following commands:

bzr pull --remember sftp://server/home/share/project/trunk
bzr push --remember sftp://server/home/share/project/trunk

Or if you're using checkouts (created on local computer with bzr checkout command) then update master branch location with command:

bzr switch --force sftp://server/home/share/project/trunk
0

精彩评论

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

关注公众号