73
77
Let's change a file and commit that change to your branch.
75
Edit ``test1.txt`` in your favourite editor, then check what have you done::
79
Edit ``test1.txt`` in your favourite editor, then use ``bzr add`` to tell bzr
80
to track changes to this file ::
82
$ echo test test test > test1.txt
86
`bzr diff` shows the changes between the last revision in this branch, and your
87
current tree (or, with the ``-r`` option, between any two trees). ::
78
90
=== modified file 'test1.txt'
93
106
You can see the history of your branch by browsing its log::
96
------------------------------------------------------------
98
committer: John Doe <john.doe@gmail.com>
99
branch nick: myproject
100
timestamp: Mon 2007-10-08 17:56:14 +0000
102
Added first line of text
103
------------------------------------------------------------
105
110
committer: John Doe <john.doe@gmail.com>
106
branch nick: myproject
107
112
timestamp: Mon 2006-10-08 17:46:22 +0000
116
121
software projects. You can use it to publish your branch. (You can
117
122
also publish branches onto your own server or other hosting services.)
119
If you don't have a Launchpad account, follow the `account signup guide`_
120
and `register an SSH key`_ in your new Launchpad account.
122
.. _account signup guide: https://help.launchpad.net/CreatingYourLaunchpadAccount
123
.. _register an SSH key: https://launchpad.net/people/+me/+editsshkeys
125
Replacing ``john.doe`` with your own Launchpad username, type::
127
$ bzr push lp:~john.doe/+junk/myproject
129
**Note**: ``+junk`` is a place to store experimental branches not
130
associated with any particular project. Normally, you should push a
131
project into an existing project, or register a new project through the
134
Now, anyone can create their own copy of your branch by typing::
136
$ bzr branch lp:~john.doe/+junk/myproject
138
You can also see information about your branch, including its revision
139
history, at https://code.launchpad.net/people/+me/+junk/myproject
124
The steps to publishing branches on Launchpad are:
126
1. Create a Launchpad account: visit the `Launchpad login page`_ and choose to create a new account.
128
.. _Launchpad login page: https://launchpad.net/+login
130
2. Bazaar uses the SSH encryption and authentication protocol to connect
131
to Launchpad. You need to first `create an SSH key`_ on your own computer,
132
by running the command::
136
.. _create an SSH key: https://help.launchpad.net/YourAccount/CreatingAnSSHKeyPair
138
3. `Upload your SSH public key to Launchpad`_.
140
.. _Upload your SSH public key to Launchpad: https://launchpad.net/~/+editsshkeys
142
4. `Make a team for your project`_. Even if you're starting as the only
143
developer on this project, creating a new now will let you more easily
144
add other people later.
146
.. _Make a team for your project: https://help.launchpad.net/Teams/CreatingAndRunning
148
5. `Create a project`_.
150
.. _Create a project: https://help.launchpad.net/Projects/Registering
152
6. Tell Bazaar your Launchpad account name. If your account is john.doe, type ::
154
$ bzr launchpad-login john.doe
156
7. `Push the branch for your project`_. Once you've committed your changes
157
locally, you can publish them as the trunk of your new project by saying
159
$ bzr push lp:~sample-developers/sample/trunk
161
(Of course, using the team and project names you just chose.)
163
.. _Push the branch for your project: https://help.launchpad.net/Code/UploadingABranch
142
165
Creating your own copy of another branch
143
166
========================================