You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.rst
+23-3Lines changed: 23 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,11 +29,31 @@ Non-Goals:
29
29
Development
30
30
-----------
31
31
32
+
For many tasks, it is okay to just develop using a single installed python version. But if you need to test/debug the project in multiple python versions, you need to install those version::
33
+
34
+
1. (Optional) Install multiple python versions
35
+
36
+
1. (Optional) Install [pyenv](https://github.com/pyenv/pyenv-installer) to manage python versions
37
+
2. (Optional) Using pyenv, install the python versions used in testing::
38
+
39
+
pyenv install 2.7.16
40
+
pyenv install 3.6.8
41
+
42
+
It may be okay to run and test python against locally installed libraries, but if you need to have a consistent build, it is recommended to manage your environment using virtualenv: [virtualenv](https://virtualenv.pypa.io/en/latest/ ), [virtualenvwrapper](https://pypi.org/project/virtualenvwrapper/ ):
43
+
44
+
1. (Optional) Setup a local virtual environment with all necessary tools and libraries::
45
+
46
+
mkvirtualenv cpplint [-p /usr/bin/python3]
47
+
pip install .[dev]
48
+
49
+
Alternatively you can locally install patches like this::
50
+
51
+
pip install --user -e .[dev]
52
+
32
53
You can setup your local environment for developing patches for cpplint like this:
33
54
34
55
.. code-block:: bash
35
56
36
-
pip install --user -e .[dev]
37
57
./setup.py lint
38
58
./setup.py style
39
59
./setup.py test
@@ -53,12 +73,12 @@ To release a new version:
53
73
git commit -m "Releasing x.y.z"
54
74
git add cpplint.py changelog.rst
55
75
# test-release (on env by mkvirtualenv -p /usr/bin/python3)
56
-
pip install --upgrade setuptools wheels twine
76
+
pip install --upgrade setuptools wheel twine
57
77
twine upload --repository testpypi dist/*
58
78
# ... Check website and downloads from https://test.pypi.org/project/cpplint/
0 commit comments