@@ -5,7 +5,7 @@ Contributing to bpython
55
66Thanks for working on bpython!
77
8- On the `GitHub issue tracker `_ some issues are labeled bite-size _
8+ On the `GitHub issue tracker `_ some issues are labeled bite-size _ -
99these are particularly good ones to start out with.
1010
1111See our section about the :ref: `community ` for a list of resources.
@@ -16,43 +16,55 @@ to get a question answered depending on the time of day.
1616Getting your development environment set up
1717-------------------------------------------
1818
19+ bpython supports Python 2.6, 2.7, 3.3 and 3.4. The code is written in Python
20+ 2 and transformed for Python 3 with 2to3. This means that it's easier
21+ to work on bpython with Python 2 because it's you can use `python setup.py develop `
22+ (`development mode
23+ <https://pythonhosted.org/setuptools/setuptools.html#development-mode> `_ installs
24+ by linking to the bpython source instead of copying it over)
25+ in a more straightforward way to have your changes immediately reflected by
26+ your bpython installation and the `bpython `, `bpython-curtsies `, and `bpython-urwid `
27+ commands.
28+
1929Using a virtual environment is probably a good idea. Create a virtual environment with
2030
2131.. code-block :: bash
2232
23- $ virtualenv bpython-dev
24- $ source bpython-dev/bin/activate # this step is necssary every time you work on bpython
25- < hack on bpython>
26- $ deactivate # back to normal system environment
33+ $ virtualenv bpython-dev # determines Python version used
34+ $ source bpython-dev/bin/activate # necssary every time you work on bpython
2735
28- Fork ` bpython ` in the GitHub web interface, then clone the repo:
36+ Fork bpython in the GitHub web interface, then clone the repo:
2937
3038.. code-block :: bash
3139
3240 $ git clone git@github.com:YOUR_GITHUB_USERNAME/bpython.git
41+ $ # or "git clone https://github.com/YOUR_GITHUB_USERNAME/bpython.git"
3342
34- Next install this development version of ` bpython ` :
43+ Next install the dependencies and install your development copy of bpython:
3544
3645.. code-block :: bash
3746
38- $ pip install pygments curtsies greenlet watchdog urwid # install all the dependencies
39- $ pip install sphinx mock # development dependencies
47+ $ pip install pygments requests # install required dependencies
48+ $ pip install curtsies greenlet watchdog urwid # install optional dependencies
49+ $ pip install sphinx mock nosetests # development dependencies
4050 $ cd bpython
4151 $ python setup.py develop
4252 < modify a file in some way>
4353 $ bpython-curtsies # this runs your modified copy of bpython!
4454
4555 As a first dev task, I recommend getting `bpython ` to print your name every time you hit a specific key.
4656
47- To run tests:
57+ To run tests from the bpython directory:
58+
59+ .. code-block :: bash
4860
49- $ python -m unittest discover bpython
61+ $ nosetests
5062
5163 To build the docs:
5264------------------
5365
54- The documentation is included in the regular ` bpython ` repository. After
55- checking out the ` bpython ` repository and installing `sphinx ` as described in
66+ The documentation is included in the bpython repository. After
67+ checking out the bpython repository and installing `sphinx ` as described in
5668the previous step, you can run the following command in your checkout of the
5769repository to build the documentation:
5870
@@ -63,7 +75,6 @@ repository to build the documentation:
6375 Afterwards you can point your browser to `doc/sphinx/build/html/index.html `.
6476Don't forget to recreate the HTML after you make changes.
6577
66-
6778To hack on the site or theme
6879----------------------------
6980
0 commit comments