/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to doc/developers/contribution-quickstart.txt

  • Committer: Martin
  • Date: 2018-11-18 19:48:57 UTC
  • mto: This revision was merged to the branch mainline in revision 7205.
  • Revision ID: gzlist@googlemail.com-20181118194857-mqty4xka790jf934
Fix remaining whitespace lint in codebase

Enables rules W191, W291, W293, and W391 for flake8.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Contributing to Bazaar
 
2
======================
 
3
 
 
4
Talk to us
 
5
----------
 
6
 
 
7
If you want to fix or improve something in Bazaar, we want to help you.
 
8
You can ask at any time for help, on the list, on irc, or through a merge
 
9
proposal on Launchpad.
 
10
 
 
11
* `Bazaar mailing list <http://lists.ubuntu.com/mailman/listinfo/bazaar>`_
 
12
 
 
13
* IRC in channel ``#bzr`` on ``irc.freenode.net``
 
14
 
 
15
 
 
16
Starting
 
17
--------
 
18
 
 
19
Before starting on a change it's a good idea to either file a bug, find a
 
20
relevant existing bug, or send a proposal to the list.  If there is a bug
 
21
you should set it to "In Progress" and if you wish assign it to yourself.
 
22
 
 
23
You might like to start with a bug tagged `easy
 
24
<https://bugs.launchpad.net/bzr/+bugs?field.tag=easy>`_.
 
25
 
 
26
If you are wondering if your understanding of the bug is correct, or if the 
 
27
approach you have in mind is likely to work, feel to ask about it on the bug,
 
28
in ``#bzr`` or on the mailing list.
 
29
 
 
30
Making a branch
 
31
---------------
 
32
 
 
33
First, get a local copy of Bazaar::
 
34
 
 
35
   $ cd $HOME
 
36
   $ bzr init-repo bzr
 
37
   $ cd bzr
 
38
   $ bzr branch lp:bzr bzr.dev
 
39
 
 
40
Now make your own branch; we recommend you include the bug number and also
 
41
a brief description::
 
42
 
 
43
   $ bzr branch bzr.dev 123456-status-speed
 
44
 
 
45
and go ahead and commit in there.  Normally you should fix only one bug or
 
46
closely-related cluster of bugs per branch, to make reviews and merges
 
47
flow more smoothly.
 
48
 
 
49
For bugs that exist in older supported branches of bzr like 2.0 or 2.1,
 
50
you might want to fix the bug there so it can go into a bugfix release,
 
51
ie ::
 
52
 
 
53
   $ bzr branch lp:bzr/2.1 bzr.2.1
 
54
   $ bzr branch bzr.2.1 123458-2.1-status
 
55
 
 
56
You probably want this configuration in ``~/.bazaar/locations.conf``::
 
57
 
 
58
    [/home/USER/bzr]
 
59
    push_location = lp:~LAUNCHPAD_USER/bzr/
 
60
    push_location:policy = appendpath
 
61
    public_branch = http://bazaar.launchpad.net/~LAUNCHPAD_USER/bzr/
 
62
    public_branch:policy = appendpath
 
63
 
 
64
with your local and Launchpad usernames inserted.
 
65
 
 
66
 
 
67
 
 
68
Publishing your changes
 
69
-----------------------
 
70
 
 
71
After you've locally committed your changes, the configuration above
 
72
should be enough that you can push them to Launchpad with a simple ::
 
73
 
 
74
    $ bzr push
 
75
 
 
76
 
 
77
Writing tests
 
78
-------------
 
79
 
 
80
We value test coverage and generally all changes should have or update a
 
81
test.  There is a powerful test framework but it can be hard to find the
 
82
right place to put your test.  Don't hesitate to ask, or to propose a
 
83
merge that does not yet have tests.
 
84
 
 
85
Normally for command-line code you should look in
 
86
``breezy.tests.blackbox`` and for library code in ``breezy.tests``.  For
 
87
functions on an interface for which there are multiple implementations,
 
88
like `Transport`, look in ``breezy.tests.per_transport``.
 
89
 
 
90
It's a good idea to search the tests for something related to the thing
 
91
you're changing and you may find a test you can modify or adapt.
 
92
 
 
93
To run the tests::
 
94
 
 
95
    $ ./bzr selftest
 
96
 
 
97
Normally the tests will skip if some library dependencies are not present.
 
98
On Ubuntu, you can install them with this command (you must have source
 
99
repositories enabled in Software Sources)::
 
100
 
 
101
    $ sudo apt-get build-dep bzr
 
102
 
 
103
To build the binary extensions::
 
104
 
 
105
    $ make
 
106
 
 
107
For more information: `Testing Guide <testing.html>`_.
 
108
 
 
109
 
 
110
Proposing a merge
 
111
-----------------
 
112
 
 
113
 
 
114
Then propose a merge into bzr; for bzr 2.2 and later you can use the ``bzr
 
115
lp-propose-merge`` command.  In the comment for your merge proposal please
 
116
explain what you're trying to do and why.  For `example
 
117
<https://code.launchpad.net/~ian-clatworthy/bzr/whats-new-in-2.1/+merge/19677>`_:
 
118
 
 
119
  As discussed on the mailing list, this patch adds a What's New document
 
120
  summarising the changes since 2.0.
 
121
 
 
122
If you make additional changes to your branch you don't need to resubmit;
 
123
they'll automatically show up in the merge proposal.
 
124
 
 
125
* `Launchpad Code Review Help <http://help.launchpad.net/Code/Review>`_.
 
126
 
 
127
 
 
128
..
 
129
   vim: ft=rst tw=74 ai