Skip to content

Commit 62fc95f

Browse files
committed
Add development docs
1 parent afb3ea3 commit 62fc95f

File tree

2 files changed

+77
-0
lines changed

2 files changed

+77
-0
lines changed

README.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,13 @@ To install pytest-base-url:
3737
3838
$ pip install pytest-base-url
3939
40+
Contributing
41+
------------
42+
43+
We welcome contributions.
44+
45+
To learn more, see `Development <https://github.com/pytest-dev/pytest-base-url/blob/master/development.rst>`_
46+
4047
Specifying a Base URL
4148
---------------------
4249

development.rst

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
Development
2+
===========
3+
4+
To contribute to `pytest-html` you can use `Pipenv`_ to manage
5+
a python virtual environment and `pre-commit <https://pre-commit.com/>`_ to help you with
6+
styling and formatting.
7+
8+
To setup the virtual environment and pre-commit, run:
9+
10+
.. code-block:: bash
11+
12+
$ pipenv install --dev
13+
$ pipenv run pre-commit install
14+
15+
If you're not using `Pipenv`_, to install `pre-commit`, run:
16+
17+
.. code-block:: bash
18+
19+
$ pip install pre-commit
20+
$ pre-commit install
21+
22+
23+
Automated Testing
24+
-----------------
25+
26+
All pull requests and merges are tested in `Travis CI <https://travis-ci.org/>`_
27+
based on the ``.travis.yml`` file.
28+
29+
Usually, a link to your specific travis build appears in pull requests, but if
30+
not, you can find it on the
31+
`pull requests page <https://travis-ci.org/pytest-dev/pytest-base-url/pull_requests>`_
32+
33+
The only way to trigger Travis CI to run again for a pull request, is to submit
34+
another change to the pull branch.
35+
36+
You can do this with `git commit --allow-empty`
37+
38+
Running Tests
39+
-------------
40+
41+
You will need `Tox <http://tox.testrun.org/>`_ installed to run the tests
42+
against the supported Python versions. If you're using `Pipenv`_ it will be
43+
installed for you.
44+
45+
With `Pipenv`_, run:
46+
47+
.. code-block:: bash
48+
49+
$ pipenv run tox
50+
51+
Otherwise, to install and run, do:
52+
53+
.. code-block:: bash
54+
55+
$ pip install tox
56+
$ tox
57+
58+
Releasing a new version
59+
-----------------------
60+
61+
Follow these steps to release a new version of the project:
62+
63+
1. Update your local master with the upstream master (``git pull --rebase upstream master``)
64+
2. Create a new branch and update ``CHANGES.rst`` with the new version, today's date, and all changes/new features
65+
3. Commit and push the new branch and then create a new pull request
66+
4. Wait for tests and reviews and then merge the branch
67+
5. Once merged, update your local master again (``git pull --rebase upstream master``)
68+
6. Tag the release with the new release version (``git tag v<new tag>``)
69+
7. Push the tag (``git push upstream --tags``)
70+
8. Done. You can monitor the progress on `Travis <https://travis-ci.org/pytest-dev/pytest-base-url/>`_

0 commit comments

Comments
 (0)