From 488e859f8c343b0ef25db379b6339bf82769514b Mon Sep 17 00:00:00 2001 From: Cody Logan Date: Fri, 1 Dec 2023 11:29:31 -0800 Subject: Update README (#17) * Add Homebrew note to README * Put contributing info in separate file --- CONTRIBUTING.md | 38 ++++++++++++++++++++++++++++++++++++++ README.md | 43 ++++++++++--------------------------------- 2 files changed, 48 insertions(+), 33 deletions(-) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..bf4343a --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,38 @@ +# Contributing to wikiget + +Pull requests, bug reports, or feature requests are more than welcome. + +It's recommended that you use a [virtual environment manager][venv] like venv or [virtualenv] to create an isolated +environment in which to install this package's dependencies as not to clutter your system Python environment: + +```bash +# if you plan on submitting pull requests, fork the repo on GitHub and clone that instead +git clone https://github.com/clpo13/wikiget +cd wikiget + +python3 -m venv venv +# or +virtualenv venv +``` + +To activate the virtual environment, use one of the following commands: + +```bash +# Linux and macOS; activate.csh and activate.fish are also available +source venv/bin/activate + +# Windows (Command Prompt or PowerShell) +.\venv\Scripts\activate +``` + +Then run `pip install -e .` to invoke an ["editable" install][editable], meaning any changes made to the source will be +reflected immediately in the executable script. Unit tests can be run with `pytest` (make sure to run +`pip install pytest` in the virtual environment first.) + +Alternatively, using [Hatch], simply clone the repository and run `hatch run test` to create the environment and run +pytest all in one go. Wikiget can also be run directly in the Hatch environment with `hatch run wikiget [...]`. + +[venv]: https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/ +[virtualenv]: https://virtualenv.pypa.io/en/latest/ +[editable]: https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs +[hatch]: https://hatch.pypa.io/latest/ diff --git a/README.md b/README.md index f6b7ee1..6c70cb9 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,13 @@ from [GitHub]: pip install https://github.com/clpo13/wikiget/archive/refs/heads/master.zip ``` +Alternatively, if you have [Homebrew] installed: + +```bash +brew tap clpo13/clpo13 +brew install wikiget +``` + ## Usage `wikiget [-h] [-V] [-q | -v] [-f] [-s SITE] [-P PATH] [-u USERNAME] [-p PASSWORD] [-o OUTPUT | -a] [-l LOGFILE] [-j THREADS] FILE` @@ -75,35 +82,7 @@ wikiget https://en.wikipedia.org/wiki/File:Example.jpg -o test.jpg Pull requests, bug reports, or feature requests are more than welcome. -It's recommended that you use a [virtual environment manager][venv] like venv or [virtualenv] to create an isolated -environment in which to install this package's dependencies as not to clutter your system Python environment: - -```bash -# if you plan on submitting pull requests, fork the repo on GitHub and clone that instead -git clone https://github.com/clpo13/wikiget -cd wikiget - -python3 -m venv venv -# or -virtualenv venv -``` - -To activate the virtual environment, use one of the following commands: - -```bash -# Linux and macOS; activate.csh and activate.fish are also available -source venv/bin/activate - -# Windows (Command Prompt or PowerShell) -.\venv\Scripts\activate -``` - -Then run `pip install -e .` to invoke an ["editable" install][editable], meaning any changes made to the source will be -reflected immediately in the executable script. Unit tests can be run with `pytest` (make sure to run -`pip install pytest` in the virtual environment first.) - -Alternatively, using [Hatch], simply clone the repository and run `hatch run test` to create the environment and run -pytest all in one go. Wikiget can also be run directly in the Hatch environment with `hatch run wikiget [...]`. +See [CONTRIBUTING] for more info. ## License @@ -121,12 +100,10 @@ You should have received a copy of the GNU General Public License along with thi [wget]: https://www.gnu.org/software/wget/ [github]: https://github.com/clpo13/wikiget/ +[homebrew]: https://brew.sh/ [python]: https://www.python.org/ [action]: https://github.com/clpo13/wikiget/actions/workflows/python.yml [codecov]: https://app.codecov.io/gh/clpo13/wikiget/ [pypi]: https://pypi.org/project/wikiget/ [license]: https://github.com/clpo13/wikiget/blob/master/LICENSE -[venv]: https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/ -[virtualenv]: https://virtualenv.pypa.io/en/latest/ -[editable]: https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs -[hatch]: https://hatch.pypa.io/latest/ +[contributing]: CONTRIBUTING.md -- cgit v1.2.3