New tutorial and an intro
John Arbash Meinel
john at arbash-meinel.com
Thu Aug 14 03:18:43 BST 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
James Westby wrote:
> Oops, sorry, I hit the wrong key combo while getting
> frustrated with evolution.
>
> On Tue, 2008-08-12 at 02:19 -0400, Emma Jane Hogbin wrote:
>
>> Change directories into your project directory (note, these steps are
>> done within the project directory, not from above).
>>
>> * initalize the directory:
>> * bzr init
>> * check to see that a hidden .bzr folder has been created:
>> * ls -al
>> * add all files in your project to the revision control system:
>> * bzr add
>
> Mentioning "rm" and "ignore" may be worthwhile, so that users know
> how to avoid versioning everything.
>
>> When you are ready to upload the files to the server you will need to
>> install the bzr-push-and-update plugin.
>
> You probably realise that this isn't required for normal push, just
> to get the working tree as you desire. Perhaps that should be
> explicit.
>
>> This plugin is installed only on the laptop machine. Any changes that
>> are made on the server will be pulled back down to the laptop and
>> merged into that branch. Use the following steps to install the
>> bzr-push-and-update plugin.
>>
>> * change directories to the location where you'd like to put
>> your plugins (~/.bazaar/plugins is used in this example; this
>> directory may already exist)
>> * mkdir ~/.bazaar/plugins
>> * cd ~/.bazaar/plugins
>> * install the bzr-push-and-update plugin:
>> * bzr branch https://launchpad.net/bzr-push-and-update
>> bzr_push_and_update
>
> ~/.bazaar/plugins is effectively the required place to put this.
> Otherwise you need to be root and use the bzrlib/ directory, or
> you need to set $BZR_PLUGIN_PATH, which isn't that convenient.
>
>> Note: At this point you will not have a "checkout" directory on the
>> server. You will not be able to run the second part of this process
>> without it. At this point you must log into the server and run the
>> checkout command.
>>
>> * ssh username at servername.com
>>
>> * cd /path/on/server/to/put/files
>> * bzr checkout
>
> This could be one command as below couldn't it?
>
>> Once you've created the Bazaar branch on the server you can push the
>> files into the working tree from your laptop.
>>
>> * ssh username at servername.com bzr update /path/on/server
>
> That's not necessary at this point is it, as this will be a no-op
> with the preceeding "checkout"?
>
>> You are now ready to work from either branch on either computer. To
>> push the changes to the server repeat the push command and then the
>> bzr update via ssh. They look like this:
>>
>> * bzr push
>> sftp://username@servername.com/~/path/on/server/to/put/files
>>
>> * ssh username at servername.com bzr update /path/on/server
>
> The point of the push-and-update plugin is that it automates this.
> Presumably "bzr push-and-update" would do both the steps.
>
> Also, "bzr push" remembers the default URL to use (and so does
> push-and-update I assume), so this should just become
>
> bzr push-and-update
>
>> If you have been working on the server you will need to merge changes
>> down to your laptop.
>>
>> * bzr merge sftp://username@servername.com/~/path/on/server/
>
> Again, the URL would be remembered for subsequent runs, but will be
> necessary the first time. Maybe not worth mentioning in the
> document, but may be useful to you.
>
> Thanks,
>
> James
>
With bzr-push-and-update installed, you just need "bzr push" and it will
detect the remote location has a working tree, and thus needs "bzr update" run.
That is a newer feature, though still several months old. I don't think there
is any specific reason to have the "bzr push-and-update" command around,
unless we wanted it to also do "bzr checkout" when needed (which bzr push
*won't* do with the plugin installed.)
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFIo5YDJdeBCYSNAAMRAsSJAJ9LqeT/shX/zKbaBnra1tSkvTRWlQCgtf/2
ySKcQ6bH7tMIw905MC9rgY4=
=Ty+u
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list