transperth 0.1.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. transperth-0.1.3/.github/workflows/python-package.yml +33 -0
  2. transperth-0.1.3/.github/workflows/python-publish.yml +41 -0
  3. transperth-0.1.3/.github/workflows/release-please.yml +16 -0
  4. transperth-0.1.3/.gitignore +45 -0
  5. transperth-0.1.3/.mailmap +2 -0
  6. transperth-0.1.3/.release-please-manifest.json +3 -0
  7. transperth-0.1.3/.travis.yml +11 -0
  8. transperth-0.1.3/CHANGELOG.md +8 -0
  9. transperth-0.1.3/LICENSE +20 -0
  10. transperth-0.1.3/PKG-INFO +37 -0
  11. transperth-0.1.3/README.md +8 -0
  12. transperth-0.1.3/conftest.py +0 -0
  13. transperth-0.1.3/docs/Makefile +177 -0
  14. transperth-0.1.3/docs/make.bat +242 -0
  15. transperth-0.1.3/docs/source/conf.py +348 -0
  16. transperth-0.1.3/docs/source/index.rst +20 -0
  17. transperth-0.1.3/docs/source/modules/exceptions.rst +7 -0
  18. transperth-0.1.3/docs/source/modules/livetimes.rst +7 -0
  19. transperth-0.1.3/docs/source/packages/jp/fares.rst +7 -0
  20. transperth-0.1.3/docs/source/packages/jp/index.rst +11 -0
  21. transperth-0.1.3/docs/source/packages/jp/location.rst +6 -0
  22. transperth-0.1.3/docs/source/packages/jp/route_parser.rst +7 -0
  23. transperth-0.1.3/docs/source/packages/jp/routes.rst +7 -0
  24. transperth-0.1.3/docs/source/packages/jp/utils.rst +8 -0
  25. transperth-0.1.3/docs/source/packages/smart_rider/index.rst +9 -0
  26. transperth-0.1.3/docs/source/packages/smart_rider/post_back.rst +7 -0
  27. transperth-0.1.3/docs/source/packages/smart_rider/smart_rider.rst +7 -0
  28. transperth-0.1.3/docs/source/packages/smart_rider/trips.rst +7 -0
  29. transperth-0.1.3/docs/source/quickstart.py +46 -0
  30. transperth-0.1.3/docs/source/quickstart.rst +9 -0
  31. transperth-0.1.3/pyproject.toml +51 -0
  32. transperth-0.1.3/release-please-config.json +11 -0
  33. transperth-0.1.3/setup.cfg +4 -0
  34. transperth-0.1.3/tests/__init__.py +0 -0
  35. transperth-0.1.3/tests/conftest.py +0 -0
  36. transperth-0.1.3/tests/constants/__init__.py +0 -0
  37. transperth-0.1.3/tests/constants/fares.py +44 -0
  38. transperth-0.1.3/tests/constants/header.html +11 -0
  39. transperth-0.1.3/tests/constants/location.py +14 -0
  40. transperth-0.1.3/tests/constants/misc.html +8 -0
  41. transperth-0.1.3/tests/constants/route_parser.py +99 -0
  42. transperth-0.1.3/tests/constants/routes.html +1716 -0
  43. transperth-0.1.3/tests/constants/routes.py +10 -0
  44. transperth-0.1.3/tests/helpers/mock_utils_test_case.py +11 -0
  45. transperth-0.1.3/tests/helpers/xml_test_case.py +10 -0
  46. transperth-0.1.3/tests/jp/__init__.py +0 -0
  47. transperth-0.1.3/tests/jp/test_fares.py +77 -0
  48. transperth-0.1.3/tests/jp/test_location.py +159 -0
  49. transperth-0.1.3/tests/jp/test_route_parser.py +349 -0
  50. transperth-0.1.3/tests/jp/test_routes.py +33 -0
  51. transperth-0.1.3/tests/jp/test_utils.py +31 -0
  52. transperth-0.1.3/tests/run_cov.py +20 -0
  53. transperth-0.1.3/tests/smart_rider/__init__.py +0 -0
  54. transperth-0.1.3/tests/smart_rider/test_post_back.py +17 -0
  55. transperth-0.1.3/tests/smart_rider/test_smart_rider.py +37 -0
  56. transperth-0.1.3/transperth/__init__.py +6 -0
  57. transperth-0.1.3/transperth/assets/train_stations.json +109 -0
  58. transperth-0.1.3/transperth/exceptions.py +53 -0
  59. transperth-0.1.3/transperth/jp/__init__.py +0 -0
  60. transperth-0.1.3/transperth/jp/fares.py +115 -0
  61. transperth-0.1.3/transperth/jp/location.py +197 -0
  62. transperth-0.1.3/transperth/jp/route_parser.py +299 -0
  63. transperth-0.1.3/transperth/jp/routes.py +64 -0
  64. transperth-0.1.3/transperth/jp/utils.py +27 -0
  65. transperth-0.1.3/transperth/livetimes.py +72 -0
  66. transperth-0.1.3/transperth/silver_rails/__init__.py +1 -0
  67. transperth-0.1.3/transperth/silver_rails/reference_data.py +88 -0
  68. transperth-0.1.3/transperth/silver_rails/timetable.py +74 -0
  69. transperth-0.1.3/transperth/silver_rails/utils.py +10 -0
  70. transperth-0.1.3/transperth/smart_rider/__init__.py +0 -0
  71. transperth-0.1.3/transperth/smart_rider/post_back.py +404 -0
  72. transperth-0.1.3/transperth/smart_rider/smart_rider.py +367 -0
  73. transperth-0.1.3/transperth/smart_rider/trips.py +215 -0
  74. transperth-0.1.3/transperth.egg-info/PKG-INFO +37 -0
  75. transperth-0.1.3/transperth.egg-info/SOURCES.txt +78 -0
  76. transperth-0.1.3/transperth.egg-info/dependency_links.txt +1 -0
  77. transperth-0.1.3/transperth.egg-info/requires.txt +3 -0
  78. transperth-0.1.3/transperth.egg-info/top_level.txt +1 -0
  79. transperth-0.1.3/transperth.sublime-project +9 -0
  80. transperth-0.1.3/uv.lock +492 -0
@@ -0,0 +1,33 @@
1
+ # This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2
+ # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
3
+
4
+ name: Python package
5
+
6
+ on:
7
+ push:
8
+ branches: [ "master" ]
9
+ pull_request:
10
+ branches: [ "master" ]
11
+
12
+ jobs:
13
+ build:
14
+
15
+ runs-on: ubuntu-latest
16
+ strategy:
17
+ fail-fast: false
18
+ matrix:
19
+ python-version: ["3.9", "3.10", "3.11"]
20
+
21
+ steps:
22
+ - uses: actions/checkout@v4
23
+ - name: Set up Python ${{ matrix.python-version }}
24
+ uses: actions/setup-python@v3
25
+ with:
26
+ python-version: ${{ matrix.python-version }}
27
+ - name: Install dependencies
28
+ run: |
29
+ python -m pip install --upgrade uv
30
+ uv sync
31
+ - name: Test with pytest
32
+ run: |
33
+ uv run pytest
@@ -0,0 +1,41 @@
1
+ # This workflow will upload a Python Package using Twine when a release is created
2
+ # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries
3
+
4
+ # This workflow uses actions that are not certified by GitHub.
5
+ # They are provided by a third-party and are governed by
6
+ # separate terms of service, privacy policy, and support
7
+ # documentation.
8
+
9
+ name: Upload Python Package
10
+
11
+ on:
12
+ workflow_dispatch:
13
+ release:
14
+ types: [published]
15
+
16
+ permissions:
17
+ contents: read
18
+
19
+ jobs:
20
+ deploy:
21
+
22
+ runs-on: ubuntu-latest
23
+ environment: pypi
24
+
25
+ steps:
26
+ - uses: actions/checkout@v4
27
+ - name: Set up Python
28
+ uses: actions/setup-python@v3
29
+ with:
30
+ python-version: '3.x'
31
+ - name: Install dependencies
32
+ run: |
33
+ python -m pip install --upgrade pip
34
+ pip install build
35
+ - name: Build package
36
+ run: python -m build
37
+ - name: Publish package
38
+ uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
39
+ with:
40
+ user: __token__
41
+ password: ${{ secrets.PYPI_API_TOKEN }}
@@ -0,0 +1,16 @@
1
+ on:
2
+ push:
3
+ branches:
4
+ - master
5
+ workflow_dispatch:
6
+
7
+ name: release-please
8
+ jobs:
9
+ release-please:
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - run: npx release-please debug-config --repo-url https://github.com/Mause/pytransperth
13
+ - uses: googleapis/release-please-action@v4
14
+ with:
15
+ release-type: python
16
+ token: ${{ secrets.ACCESS_TOKEN }}
@@ -0,0 +1,45 @@
1
+ *.py[cod]
2
+
3
+ # C extensions
4
+ *.so
5
+
6
+ # Packages
7
+ *.egg
8
+ *.egg-info
9
+ dist
10
+ build
11
+ eggs
12
+ parts
13
+ bin
14
+ var
15
+ sdist
16
+ develop-eggs
17
+ .installed.cfg
18
+ lib
19
+ lib64
20
+ __pycache__
21
+
22
+ # Installer logs
23
+ pip-log.txt
24
+
25
+ # Unit test / coverage reports
26
+ .coverage
27
+ .tox
28
+ nosetests.xml
29
+
30
+ # Translations
31
+ *.mo
32
+
33
+ # Mr Developer
34
+ .mr.developer.cfg
35
+ .project
36
+ .pydevproject
37
+
38
+
39
+ # Application specific
40
+ *htmlcov*
41
+ *sublime-workspace*
42
+ *auth.json*
43
+
44
+ .pytest_cache
45
+ .venv
@@ -0,0 +1,2 @@
1
+ Elliana May <me@mause.me>
2
+ Elliana May <me@mause.me> <jack.thatch@gmail.com>
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "0.1.3"
3
+ }
@@ -0,0 +1,11 @@
1
+ language: python
2
+ python:
3
+ - "3.3"
4
+ # command to install dependencies
5
+ install: "pip install -r requirements.txt"
6
+
7
+ # command to build
8
+ before-script: "python setup.py build"
9
+
10
+ # command to run tests
11
+ script: "python setup.py test"
@@ -0,0 +1,8 @@
1
+ # Changelog
2
+
3
+ ## [0.1.3](https://github.com/Mause/pytransperth/compare/v0.1.2...v0.1.3) (2024-11-03)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * use importlib.resources instead of `__file__` ([00c9547](https://github.com/Mause/pytransperth/commit/00c9547eef901c607e392bd66b138a69f5713648))
@@ -0,0 +1,20 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2014 Dominic R. May
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
6
+ this software and associated documentation files (the "Software"), to deal in
7
+ the Software without restriction, including without limitation the rights to
8
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9
+ the Software, and to permit persons to whom the Software is furnished to do so,
10
+ subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,37 @@
1
+ Metadata-Version: 2.1
2
+ Name: transperth
3
+ Version: 0.1.3
4
+ Summary: A Python wrapper for the Transperth API
5
+ Author-email: Elliana May <me@mause.me>
6
+ License: MIT
7
+ Project-URL: repository, https://github.com/Mause/pytransperth
8
+ Classifier: Development Status :: 2 - Pre-Alpha
9
+ Classifier: Intended Audience :: Developers
10
+ Classifier: License :: OSI Approved :: MIT License
11
+ Classifier: Natural Language :: English
12
+ Classifier: Operating System :: OS Independent
13
+ Classifier: Programming Language :: Python
14
+ Classifier: Programming Language :: Python :: 3 :: Only
15
+ Classifier: Programming Language :: Python :: 3.9
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Programming Language :: Python :: 3.11
18
+ Classifier: Programming Language :: Python :: 3.12
19
+ Classifier: Programming Language :: Python :: 3.13
20
+ Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
21
+ Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
22
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
23
+ Requires-Python: >=3.9
24
+ Description-Content-Type: text/markdown
25
+ License-File: LICENSE
26
+ Requires-Dist: lxml
27
+ Requires-Dist: python-dateutil
28
+ Requires-Dist: requests
29
+
30
+ pytransperth ![](https://api.travis-ci.org/Mause/pytransperth.png)
31
+ ============
32
+
33
+ A silly attempt at creating an api for various transperth services.
34
+
35
+ Some info about discovery of the various endpoints is available here on my attempted blog; http://mause.me/blog/2014/03/07/transperth.html
36
+
37
+ Heavy use of `lxml` involved.
@@ -0,0 +1,8 @@
1
+ pytransperth ![](https://api.travis-ci.org/Mause/pytransperth.png)
2
+ ============
3
+
4
+ A silly attempt at creating an api for various transperth services.
5
+
6
+ Some info about discovery of the various endpoints is available here on my attempted blog; http://mause.me/blog/2014/03/07/transperth.html
7
+
8
+ Heavy use of `lxml` involved.
File without changes
@@ -0,0 +1,177 @@
1
+ # Makefile for Sphinx documentation
2
+ #
3
+
4
+ # You can set these variables from the command line.
5
+ SPHINXOPTS =
6
+ SPHINXBUILD = sphinx-build
7
+ PAPER =
8
+ BUILDDIR = build
9
+
10
+ # User-friendly check for sphinx-build
11
+ ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1)
12
+ $(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/)
13
+ endif
14
+
15
+ # Internal variables.
16
+ PAPEROPT_a4 = -D latex_paper_size=a4
17
+ PAPEROPT_letter = -D latex_paper_size=letter
18
+ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
19
+ # the i18n builder cannot share the environment and doctrees with the others
20
+ I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
21
+
22
+ .PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext
23
+
24
+ help:
25
+ @echo "Please use \`make <target>' where <target> is one of"
26
+ @echo " html to make standalone HTML files"
27
+ @echo " dirhtml to make HTML files named index.html in directories"
28
+ @echo " singlehtml to make a single large HTML file"
29
+ @echo " pickle to make pickle files"
30
+ @echo " json to make JSON files"
31
+ @echo " htmlhelp to make HTML files and a HTML help project"
32
+ @echo " qthelp to make HTML files and a qthelp project"
33
+ @echo " devhelp to make HTML files and a Devhelp project"
34
+ @echo " epub to make an epub"
35
+ @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
36
+ @echo " latexpdf to make LaTeX files and run them through pdflatex"
37
+ @echo " latexpdfja to make LaTeX files and run them through platex/dvipdfmx"
38
+ @echo " text to make text files"
39
+ @echo " man to make manual pages"
40
+ @echo " texinfo to make Texinfo files"
41
+ @echo " info to make Texinfo files and run them through makeinfo"
42
+ @echo " gettext to make PO message catalogs"
43
+ @echo " changes to make an overview of all changed/added/deprecated items"
44
+ @echo " xml to make Docutils-native XML files"
45
+ @echo " pseudoxml to make pseudoxml-XML files for display purposes"
46
+ @echo " linkcheck to check all external links for integrity"
47
+ @echo " doctest to run all doctests embedded in the documentation (if enabled)"
48
+
49
+ clean:
50
+ rm -rf $(BUILDDIR)/*
51
+
52
+ html:
53
+ $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
54
+ @echo
55
+ @echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
56
+
57
+ dirhtml:
58
+ $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
59
+ @echo
60
+ @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
61
+
62
+ singlehtml:
63
+ $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
64
+ @echo
65
+ @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
66
+
67
+ pickle:
68
+ $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
69
+ @echo
70
+ @echo "Build finished; now you can process the pickle files."
71
+
72
+ json:
73
+ $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
74
+ @echo
75
+ @echo "Build finished; now you can process the JSON files."
76
+
77
+ htmlhelp:
78
+ $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
79
+ @echo
80
+ @echo "Build finished; now you can run HTML Help Workshop with the" \
81
+ ".hhp project file in $(BUILDDIR)/htmlhelp."
82
+
83
+ qthelp:
84
+ $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
85
+ @echo
86
+ @echo "Build finished; now you can run "qcollectiongenerator" with the" \
87
+ ".qhcp project file in $(BUILDDIR)/qthelp, like this:"
88
+ @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/Transperth.qhcp"
89
+ @echo "To view the help file:"
90
+ @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/Transperth.qhc"
91
+
92
+ devhelp:
93
+ $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
94
+ @echo
95
+ @echo "Build finished."
96
+ @echo "To view the help file:"
97
+ @echo "# mkdir -p $$HOME/.local/share/devhelp/Transperth"
98
+ @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/Transperth"
99
+ @echo "# devhelp"
100
+
101
+ epub:
102
+ $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub
103
+ @echo
104
+ @echo "Build finished. The epub file is in $(BUILDDIR)/epub."
105
+
106
+ latex:
107
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
108
+ @echo
109
+ @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
110
+ @echo "Run \`make' in that directory to run these through (pdf)latex" \
111
+ "(use \`make latexpdf' here to do that automatically)."
112
+
113
+ latexpdf:
114
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
115
+ @echo "Running LaTeX files through pdflatex..."
116
+ $(MAKE) -C $(BUILDDIR)/latex all-pdf
117
+ @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
118
+
119
+ latexpdfja:
120
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
121
+ @echo "Running LaTeX files through platex and dvipdfmx..."
122
+ $(MAKE) -C $(BUILDDIR)/latex all-pdf-ja
123
+ @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
124
+
125
+ text:
126
+ $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text
127
+ @echo
128
+ @echo "Build finished. The text files are in $(BUILDDIR)/text."
129
+
130
+ man:
131
+ $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
132
+ @echo
133
+ @echo "Build finished. The manual pages are in $(BUILDDIR)/man."
134
+
135
+ texinfo:
136
+ $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
137
+ @echo
138
+ @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."
139
+ @echo "Run \`make' in that directory to run these through makeinfo" \
140
+ "(use \`make info' here to do that automatically)."
141
+
142
+ info:
143
+ $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
144
+ @echo "Running Texinfo files through makeinfo..."
145
+ make -C $(BUILDDIR)/texinfo info
146
+ @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo."
147
+
148
+ gettext:
149
+ $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale
150
+ @echo
151
+ @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale."
152
+
153
+ changes:
154
+ $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
155
+ @echo
156
+ @echo "The overview file is in $(BUILDDIR)/changes."
157
+
158
+ linkcheck:
159
+ $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
160
+ @echo
161
+ @echo "Link check complete; look for any errors in the above output " \
162
+ "or in $(BUILDDIR)/linkcheck/output.txt."
163
+
164
+ doctest:
165
+ $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
166
+ @echo "Testing of doctests in the sources finished, look at the " \
167
+ "results in $(BUILDDIR)/doctest/output.txt."
168
+
169
+ xml:
170
+ $(SPHINXBUILD) -b xml $(ALLSPHINXOPTS) $(BUILDDIR)/xml
171
+ @echo
172
+ @echo "Build finished. The XML files are in $(BUILDDIR)/xml."
173
+
174
+ pseudoxml:
175
+ $(SPHINXBUILD) -b pseudoxml $(ALLSPHINXOPTS) $(BUILDDIR)/pseudoxml
176
+ @echo
177
+ @echo "Build finished. The pseudo-XML files are in $(BUILDDIR)/pseudoxml."
@@ -0,0 +1,242 @@
1
+ @ECHO OFF
2
+
3
+ REM Command file for Sphinx documentation
4
+
5
+ if "%SPHINXBUILD%" == "" (
6
+ set SPHINXBUILD=sphinx-build
7
+ )
8
+ set BUILDDIR=build
9
+ set ALLSPHINXOPTS=-d %BUILDDIR%/doctrees %SPHINXOPTS% source
10
+ set I18NSPHINXOPTS=%SPHINXOPTS% source
11
+ if NOT "%PAPER%" == "" (
12
+ set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS%
13
+ set I18NSPHINXOPTS=-D latex_paper_size=%PAPER% %I18NSPHINXOPTS%
14
+ )
15
+
16
+ if "%1" == "" goto help
17
+
18
+ if "%1" == "help" (
19
+ :help
20
+ echo.Please use `make ^<target^>` where ^<target^> is one of
21
+ echo. html to make standalone HTML files
22
+ echo. dirhtml to make HTML files named index.html in directories
23
+ echo. singlehtml to make a single large HTML file
24
+ echo. pickle to make pickle files
25
+ echo. json to make JSON files
26
+ echo. htmlhelp to make HTML files and a HTML help project
27
+ echo. qthelp to make HTML files and a qthelp project
28
+ echo. devhelp to make HTML files and a Devhelp project
29
+ echo. epub to make an epub
30
+ echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter
31
+ echo. text to make text files
32
+ echo. man to make manual pages
33
+ echo. texinfo to make Texinfo files
34
+ echo. gettext to make PO message catalogs
35
+ echo. changes to make an overview over all changed/added/deprecated items
36
+ echo. xml to make Docutils-native XML files
37
+ echo. pseudoxml to make pseudoxml-XML files for display purposes
38
+ echo. linkcheck to check all external links for integrity
39
+ echo. doctest to run all doctests embedded in the documentation if enabled
40
+ goto end
41
+ )
42
+
43
+ if "%1" == "clean" (
44
+ for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i
45
+ del /q /s %BUILDDIR%\*
46
+ goto end
47
+ )
48
+
49
+
50
+ %SPHINXBUILD% 2> nul
51
+ if errorlevel 9009 (
52
+ echo.
53
+ echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
54
+ echo.installed, then set the SPHINXBUILD environment variable to point
55
+ echo.to the full path of the 'sphinx-build' executable. Alternatively you
56
+ echo.may add the Sphinx directory to PATH.
57
+ echo.
58
+ echo.If you don't have Sphinx installed, grab it from
59
+ echo.http://sphinx-doc.org/
60
+ exit /b 1
61
+ )
62
+
63
+ if "%1" == "html" (
64
+ %SPHINXBUILD% -b html %ALLSPHINXOPTS% %BUILDDIR%/html
65
+ if errorlevel 1 exit /b 1
66
+ echo.
67
+ echo.Build finished. The HTML pages are in %BUILDDIR%/html.
68
+ goto end
69
+ )
70
+
71
+ if "%1" == "dirhtml" (
72
+ %SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% %BUILDDIR%/dirhtml
73
+ if errorlevel 1 exit /b 1
74
+ echo.
75
+ echo.Build finished. The HTML pages are in %BUILDDIR%/dirhtml.
76
+ goto end
77
+ )
78
+
79
+ if "%1" == "singlehtml" (
80
+ %SPHINXBUILD% -b singlehtml %ALLSPHINXOPTS% %BUILDDIR%/singlehtml
81
+ if errorlevel 1 exit /b 1
82
+ echo.
83
+ echo.Build finished. The HTML pages are in %BUILDDIR%/singlehtml.
84
+ goto end
85
+ )
86
+
87
+ if "%1" == "pickle" (
88
+ %SPHINXBUILD% -b pickle %ALLSPHINXOPTS% %BUILDDIR%/pickle
89
+ if errorlevel 1 exit /b 1
90
+ echo.
91
+ echo.Build finished; now you can process the pickle files.
92
+ goto end
93
+ )
94
+
95
+ if "%1" == "json" (
96
+ %SPHINXBUILD% -b json %ALLSPHINXOPTS% %BUILDDIR%/json
97
+ if errorlevel 1 exit /b 1
98
+ echo.
99
+ echo.Build finished; now you can process the JSON files.
100
+ goto end
101
+ )
102
+
103
+ if "%1" == "htmlhelp" (
104
+ %SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% %BUILDDIR%/htmlhelp
105
+ if errorlevel 1 exit /b 1
106
+ echo.
107
+ echo.Build finished; now you can run HTML Help Workshop with the ^
108
+ .hhp project file in %BUILDDIR%/htmlhelp.
109
+ goto end
110
+ )
111
+
112
+ if "%1" == "qthelp" (
113
+ %SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% %BUILDDIR%/qthelp
114
+ if errorlevel 1 exit /b 1
115
+ echo.
116
+ echo.Build finished; now you can run "qcollectiongenerator" with the ^
117
+ .qhcp project file in %BUILDDIR%/qthelp, like this:
118
+ echo.^> qcollectiongenerator %BUILDDIR%\qthelp\Transperth.qhcp
119
+ echo.To view the help file:
120
+ echo.^> assistant -collectionFile %BUILDDIR%\qthelp\Transperth.ghc
121
+ goto end
122
+ )
123
+
124
+ if "%1" == "devhelp" (
125
+ %SPHINXBUILD% -b devhelp %ALLSPHINXOPTS% %BUILDDIR%/devhelp
126
+ if errorlevel 1 exit /b 1
127
+ echo.
128
+ echo.Build finished.
129
+ goto end
130
+ )
131
+
132
+ if "%1" == "epub" (
133
+ %SPHINXBUILD% -b epub %ALLSPHINXOPTS% %BUILDDIR%/epub
134
+ if errorlevel 1 exit /b 1
135
+ echo.
136
+ echo.Build finished. The epub file is in %BUILDDIR%/epub.
137
+ goto end
138
+ )
139
+
140
+ if "%1" == "latex" (
141
+ %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex
142
+ if errorlevel 1 exit /b 1
143
+ echo.
144
+ echo.Build finished; the LaTeX files are in %BUILDDIR%/latex.
145
+ goto end
146
+ )
147
+
148
+ if "%1" == "latexpdf" (
149
+ %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex
150
+ cd %BUILDDIR%/latex
151
+ make all-pdf
152
+ cd %BUILDDIR%/..
153
+ echo.
154
+ echo.Build finished; the PDF files are in %BUILDDIR%/latex.
155
+ goto end
156
+ )
157
+
158
+ if "%1" == "latexpdfja" (
159
+ %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex
160
+ cd %BUILDDIR%/latex
161
+ make all-pdf-ja
162
+ cd %BUILDDIR%/..
163
+ echo.
164
+ echo.Build finished; the PDF files are in %BUILDDIR%/latex.
165
+ goto end
166
+ )
167
+
168
+ if "%1" == "text" (
169
+ %SPHINXBUILD% -b text %ALLSPHINXOPTS% %BUILDDIR%/text
170
+ if errorlevel 1 exit /b 1
171
+ echo.
172
+ echo.Build finished. The text files are in %BUILDDIR%/text.
173
+ goto end
174
+ )
175
+
176
+ if "%1" == "man" (
177
+ %SPHINXBUILD% -b man %ALLSPHINXOPTS% %BUILDDIR%/man
178
+ if errorlevel 1 exit /b 1
179
+ echo.
180
+ echo.Build finished. The manual pages are in %BUILDDIR%/man.
181
+ goto end
182
+ )
183
+
184
+ if "%1" == "texinfo" (
185
+ %SPHINXBUILD% -b texinfo %ALLSPHINXOPTS% %BUILDDIR%/texinfo
186
+ if errorlevel 1 exit /b 1
187
+ echo.
188
+ echo.Build finished. The Texinfo files are in %BUILDDIR%/texinfo.
189
+ goto end
190
+ )
191
+
192
+ if "%1" == "gettext" (
193
+ %SPHINXBUILD% -b gettext %I18NSPHINXOPTS% %BUILDDIR%/locale
194
+ if errorlevel 1 exit /b 1
195
+ echo.
196
+ echo.Build finished. The message catalogs are in %BUILDDIR%/locale.
197
+ goto end
198
+ )
199
+
200
+ if "%1" == "changes" (
201
+ %SPHINXBUILD% -b changes %ALLSPHINXOPTS% %BUILDDIR%/changes
202
+ if errorlevel 1 exit /b 1
203
+ echo.
204
+ echo.The overview file is in %BUILDDIR%/changes.
205
+ goto end
206
+ )
207
+
208
+ if "%1" == "linkcheck" (
209
+ %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% %BUILDDIR%/linkcheck
210
+ if errorlevel 1 exit /b 1
211
+ echo.
212
+ echo.Link check complete; look for any errors in the above output ^
213
+ or in %BUILDDIR%/linkcheck/output.txt.
214
+ goto end
215
+ )
216
+
217
+ if "%1" == "doctest" (
218
+ %SPHINXBUILD% -b doctest %ALLSPHINXOPTS% %BUILDDIR%/doctest
219
+ if errorlevel 1 exit /b 1
220
+ echo.
221
+ echo.Testing of doctests in the sources finished, look at the ^
222
+ results in %BUILDDIR%/doctest/output.txt.
223
+ goto end
224
+ )
225
+
226
+ if "%1" == "xml" (
227
+ %SPHINXBUILD% -b xml %ALLSPHINXOPTS% %BUILDDIR%/xml
228
+ if errorlevel 1 exit /b 1
229
+ echo.
230
+ echo.Build finished. The XML files are in %BUILDDIR%/xml.
231
+ goto end
232
+ )
233
+
234
+ if "%1" == "pseudoxml" (
235
+ %SPHINXBUILD% -b pseudoxml %ALLSPHINXOPTS% %BUILDDIR%/pseudoxml
236
+ if errorlevel 1 exit /b 1
237
+ echo.
238
+ echo.Build finished. The pseudo-XML files are in %BUILDDIR%/pseudoxml.
239
+ goto end
240
+ )
241
+
242
+ :end