Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update Makefile with sphinx targets
  • Loading branch information
AA-Turner committed Jun 8, 2021
commit 855cf8bd9f59b303425edfbf0d06da7f63a458c4
30 changes: 24 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Rules to only make the required HTML versions, not all of them,
# without the user having to keep track of which.
#
# Not really important, but convenient.
# Builds PEP files to HTML using sphinx
# Also contains testing targets

PEP2HTML=pep2html.py

Expand Down Expand Up @@ -34,7 +32,6 @@ install:

clean:
-rm pep-0000.rst
-rm pep-0000.txt
-rm *.html
-rm -rf build

Expand All @@ -43,7 +40,7 @@ update:

venv:
$(PYTHON) -m venv $(VENV_DIR)
./$(VENV_DIR)/bin/python -m pip install -U docutils
./$(VENV_DIR)/bin/python -m pip install -r requirements.txt

package: all rss
mkdir -p build/peps
Expand All @@ -57,3 +54,24 @@ package: all rss
lint:
pre-commit --version > /dev/null || python3 -m pip install pre-commit
pre-commit run --all-files

pages: rss
$(PYTHON) build.py --index-file

sphinx:
$(PYTHON) build.py

fail_on_warning:
$(PYTHON) build.py -f

check_links:
$(PYTHON) build.py -c

sphinx_package: all rss
mkdir -p package/peps
$(PYTHON) package.py
cp pep-*.txt build/peps/
cp pep-*.rst build/peps/
cp *.png build/peps/
cp *.rss package/peps
tar -C package -czf package/peps.tar.gz peps