mirror of
https://github.com/cheat/cheat.git
synced 2024-11-23 22:41:35 +01:00
Use setuptools if possible, add development docs
- If setuptools is available, use that. Setuptools can be very handy in development, because it provides `python setup.py develop`. - Add development documentation, explaining how to use setuptools' develop with a virtual environment to work on cheat. - Backwards compatibility with distutils is maintained. If setuptools is not available, distutils will be used.
This commit is contained in:
parent
eff042d50b
commit
ad6d567d87
1
.gitignore
vendored
1
.gitignore
vendored
@ -3,3 +3,4 @@ MANIFEST
|
||||
build
|
||||
cheat.egg-info
|
||||
dist
|
||||
venv
|
||||
|
21
README.md
21
README.md
@ -117,6 +117,27 @@ enable this feature, set a `CHEATCOLORS` environment variable:
|
||||
export CHEATCOLORS=true
|
||||
```
|
||||
|
||||
Development
|
||||
-----------
|
||||
|
||||
Virtual environments and `setuptools` can be used to develop `cheat`:
|
||||
|
||||
Create a virtual environment with [virtualenv](http://docs.python-guide.org/en/latest/dev/virtualenvs/):
|
||||
|
||||
$ virtualenv venv
|
||||
|
||||
Activate it:
|
||||
|
||||
$ source venv/bin/activate
|
||||
|
||||
Install `cheat` in the venv in [development mode](http://setuptools.readthedocs.io/en/latest/setuptools.html#development-mode):
|
||||
|
||||
$ python setup.py develop
|
||||
|
||||
Now `cheat` can be run from inside the venv:
|
||||
|
||||
$ venv/bin/cheat
|
||||
|
||||
See Also:
|
||||
---------
|
||||
- [Enabling Command-line Autocompletion][autocompletion]
|
||||
|
Loading…
Reference in New Issue
Block a user