Merge ~jugmac00/lazr.delegates:publish-docs-on-rtd into lazr.delegates:main

Proposed by Jürgen Gmach
Status: Merged
Merged at revision: 04d366a5b4632f653297e21dcb93fcf61d6c6321
Proposed branch: ~jugmac00/lazr.delegates:publish-docs-on-rtd
Merge into: lazr.delegates:main
Diff against target: 290 lines (+45/-83)
9 files modified
.gitignore (+1/-0)
CONTRIBUTING.rst (+10/-12)
README.rst (+0/-20)
lazr/delegates/docs/CONTRIBUTING.rst (+1/-0)
lazr/delegates/docs/NEWS.rst (+1/-0)
lazr/delegates/docs/conf.py (+14/-51)
lazr/delegates/docs/index.rst (+7/-0)
setup.py (+3/-0)
tox.ini (+8/-0)
Reviewer Review Type Date Requested Status
Colin Watson (community) Approve
Review via email: mp+411358@code.launchpad.net

Commit message

Publish documentation on Read the Docs

To post a comment you must log in.
Revision history for this message
Colin Watson (cjwatson) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/.gitignore b/.gitignore
index 8271f5a..daeb903 100644
--- a/.gitignore
+++ b/.gitignore
@@ -13,3 +13,4 @@ __pycache__
13.coverage13.coverage
14.tox14.tox
15*.pyc15*.pyc
16lazr/delegates/docs/_build
diff --git a/HACKING.rst b/CONTRIBUTING.rst
16similarity index 78%17similarity index 78%
17rename from HACKING.rst18rename from HACKING.rst
18rename to CONTRIBUTING.rst19rename to CONTRIBUTING.rst
index 55984d8..5421a96 100644
--- a/HACKING.rst
+++ b/CONTRIBUTING.rst
@@ -23,6 +23,16 @@ please see the common hacking guidelines at:
23 http://dev.launchpad.net/Hacking23 http://dev.launchpad.net/Hacking
2424
2525
26============
27Contributing
28============
29
30To run this project's tests, use `tox <https://tox.readthedocs.io/en/latest/>`_.
31
32To update the `project's documentation
33<https://lazrdelegates.readthedocs.io/en/latest/>`_ you need to trigger a manual
34build on the project's dashboard on https://readthedocs.org.
35
26Getting help36Getting help
27------------37------------
2838
@@ -37,15 +47,3 @@ If you want to discuss this package, join the team and mailing list here:
37or send a message to:47or send a message to:
3848
39 lazr-developers@lists.launchpad.net49 lazr-developers@lists.launchpad.net
40
41
42Running the tests
43=================
44
45The tests suite requires tox_ and nose_ and is compatible with both Python 2
46and Python 3. To run the full test suite::
47
48 $ tox
49
50.. _nose: https://nose.readthedocs.org/en/latest/
51.. _tox: https://testrun.org/tox/latest/
diff --git a/README.rst b/README.rst
index d7cdc5d..82e28dd 100644
--- a/README.rst
+++ b/README.rst
@@ -1,21 +1 @@
1=========================
2Welcome to lazr.delegates1Welcome to lazr.delegates
3=========================
4
5Contents:
6
7.. toctree::
8 :maxdepth: 2
9
10 lazr/delegates/docs/usage
11 NEWS
12 HACKING
13
14
15
16Indices and tables
17==================
18
19* :ref:`genindex`
20* :ref:`modindex`
21* :ref:`search`
diff --git a/lazr/delegates/docs/CONTRIBUTING.rst b/lazr/delegates/docs/CONTRIBUTING.rst
22new file mode 1200002new file mode 120000
index 0000000..ac9338f
--- /dev/null
+++ b/lazr/delegates/docs/CONTRIBUTING.rst
@@ -0,0 +1 @@
1../../../CONTRIBUTING.rst
0\ No newline at end of file2\ No newline at end of file
diff --git a/lazr/delegates/docs/NEWS.rst b/lazr/delegates/docs/NEWS.rst
1new file mode 1200003new file mode 120000
index 0000000..c95df2b
--- /dev/null
+++ b/lazr/delegates/docs/NEWS.rst
@@ -0,0 +1 @@
1../../../NEWS.rst
0\ No newline at end of file2\ No newline at end of file
diff --git a/conf.py b/lazr/delegates/docs/conf.py
1similarity index 79%3similarity index 79%
2rename from conf.py4rename from conf.py
3rename to lazr/delegates/docs/conf.py5rename to lazr/delegates/docs/conf.py
index 4b9d3d4..e6ba426 100644
--- a/conf.py
+++ b/lazr/delegates/docs/conf.py
@@ -11,9 +11,6 @@
11# All configuration values have a default; values that are commented out11# All configuration values have a default; values that are commented out
12# serve to show the default.12# serve to show the default.
1313
14from __future__ import print_function
15import sys, os
16
17# If extensions (or modules to document with autodoc) are in another directory,14# If extensions (or modules to document with autodoc) are in another directory,
18# add these directories to sys.path here. If the directory is relative to the15# add these directories to sys.path here. If the directory is relative to the
19# documentation root, use os.path.abspath to make it absolute, like shown here.16# documentation root, use os.path.abspath to make it absolute, like shown here.
@@ -38,19 +35,18 @@ source_suffix = '.rst'
38#source_encoding = 'utf-8-sig'35#source_encoding = 'utf-8-sig'
3936
40# The master toctree document.37# The master toctree document.
41master_doc = 'README'38master_doc = 'index'
4239
43# General information about the project.40# General information about the project.
44project = u'lazr.delegates'41project = 'lazr.delegates'
45copyright = u'2013-2015, LAZR developers'42copyright = '2013-2021, LAZR developers'
4643
47# The version info for the project you're documenting, acts as replacement for44# The version info for the project you're documenting, acts as replacement for
48# |version| and |release|, also used in various other places throughout the45# |version| and |release|, also used in various other places throughout the
49# built documents.46# built documents.
50#47#
51# The short X.Y version.48# The short X.Y version.
52with open('lazr/delegates/_version.py') as version_file:49from lazr.delegates import __version__
53 exec(version_file.read()) # sets __version__
54version = __version__50version = __version__
55# The full version, including alpha/beta/rc tags.51# The full version, including alpha/beta/rc tags.
56release = version52release = version
@@ -94,7 +90,7 @@ pygments_style = 'sphinx'
9490
95# The theme to use for HTML and HTML Help pages. See the documentation for91# The theme to use for HTML and HTML Help pages. See the documentation for
96# a list of builtin themes.92# a list of builtin themes.
97html_theme = 'default'93html_theme = 'alabaster'
9894
99# Theme options are theme-specific and customize the look and feel of a theme95# Theme options are theme-specific and customize the look and feel of a theme
100# further. For a list of options available for each theme, see the96# further. For a list of options available for each theme, see the
@@ -123,7 +119,7 @@ html_theme = 'default'
123# Add any paths that contain custom static files (such as style sheets) here,119# Add any paths that contain custom static files (such as style sheets) here,
124# relative to this directory. They are copied after the builtin static files,120# relative to this directory. They are copied after the builtin static files,
125# so a file named "default.css" will overwrite the builtin "default.css".121# so a file named "default.css" will overwrite the builtin "default.css".
126html_static_path = ['_static']122html_static_path = []
127123
128# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,124# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
129# using the given strftime format.125# using the given strftime format.
@@ -134,8 +130,11 @@ html_static_path = ['_static']
134#html_use_smartypants = True130#html_use_smartypants = True
135131
136# Custom sidebar templates, maps document names to template names.132# Custom sidebar templates, maps document names to template names.
137#html_sidebars = {}133html_sidebars = {
138134 '**': [
135 'globaltoc.html',
136 ]
137}
139# Additional templates that should be rendered to pages, maps page names to138# Additional templates that should be rendered to pages, maps page names to
140# template names.139# template names.
141#html_additional_pages = {}140#html_additional_pages = {}
@@ -172,7 +171,7 @@ htmlhelp_basename = 'lazrdelegatesdoc'
172171
173# -- Options for LaTeX output --------------------------------------------------172# -- Options for LaTeX output --------------------------------------------------
174173
175latex_elements = {174# latex_elements = {
176# The paper size ('letterpaper' or 'a4paper').175# The paper size ('letterpaper' or 'a4paper').
177#'papersize': 'letterpaper',176#'papersize': 'letterpaper',
178177
@@ -181,14 +180,10 @@ latex_elements = {
181180
182# Additional stuff for the LaTeX preamble.181# Additional stuff for the LaTeX preamble.
183#'preamble': '',182#'preamble': '',
184}183# }
185184
186# Grouping the document tree into LaTeX files. List of tuples185# Grouping the document tree into LaTeX files. List of tuples
187# (source start file, target name, title, author, documentclass [howto/manual]).186# (source start file, target name, title, author, documentclass [howto/manual]).
188latex_documents = [
189 ('index', 'lazrdelegates.tex', u'lazr.delegates Documentation',
190 u'LAZR developers', 'manual'),
191]
192187
193# The name of an image file (relative to this directory) to place at the top of188# The name of an image file (relative to this directory) to place at the top of
194# the title page.189# the title page.
@@ -215,10 +210,6 @@ latex_documents = [
215210
216# One entry per manual page. List of tuples211# One entry per manual page. List of tuples
217# (source start file, name, description, authors, manual section).212# (source start file, name, description, authors, manual section).
218man_pages = [
219 ('index', 'lazrdelegates', u'lazr.delegates Documentation',
220 [u'LAZR developers'], 1)
221]
222213
223# If true, show URL addresses after external links.214# If true, show URL addresses after external links.
224#man_show_urls = False215#man_show_urls = False
@@ -229,11 +220,6 @@ man_pages = [
229# Grouping the document tree into Texinfo files. List of tuples220# Grouping the document tree into Texinfo files. List of tuples
230# (source start file, target name, title, author,221# (source start file, target name, title, author,
231# dir menu entry, description, category)222# dir menu entry, description, category)
232texinfo_documents = [
233 ('index', 'lazrdelegates', u'lazr.delegates Documentation',
234 u'LAZR developers', 'lazrdelegates', 'One line description of project.',
235 'Miscellaneous'),
236]
237223
238# Documents to append as an appendix to all manuals.224# Documents to append as an appendix to all manuals.
239#texinfo_appendices = []225#texinfo_appendices = []
@@ -242,27 +228,4 @@ texinfo_documents = [
242#texinfo_domain_indices = True228#texinfo_domain_indices = True
243229
244# How to display URL addresses: 'footnote', 'no', or 'inline'.230# How to display URL addresses: 'footnote', 'no', or 'inline'.
245#texinfo_show_urls = 'footnote'231#texinfo_show_urls = 'footnote'
246
247# Make upload to packages.python.org happy.
248def index_html():
249 import errno
250 cwd = os.getcwd()
251 try:
252 try:
253 os.makedirs('build/sphinx/html')
254 except OSError as error:
255 if error.errno != errno.EEXIST:
256 raise
257 os.chdir('build/sphinx/html')
258 try:
259 os.symlink('README.html', 'index.html')
260 print('index.html -> README.html')
261 except OSError as error:
262 if error.errno != errno.EEXIST:
263 raise
264 finally:
265 os.chdir(cwd)
266
267import atexit
268atexit.register(index_html)
269\ No newline at end of file232\ No newline at end of file
diff --git a/lazr/delegates/docs/usage.rst b/lazr/delegates/docs/index.rst
270similarity index 97%233similarity index 97%
271rename from lazr/delegates/docs/usage.rst234rename from lazr/delegates/docs/usage.rst
272rename to lazr/delegates/docs/index.rst235rename to lazr/delegates/docs/index.rst
index 82dc85e..b593f9e 100644
--- a/lazr/delegates/docs/usage.rst
+++ b/lazr/delegates/docs/index.rst
@@ -134,3 +134,10 @@ the expected interfaces.
134 True134 True
135 >>> IFoo2.providedBy(s)135 >>> IFoo2.providedBy(s)
136 True136 True
137
138
139.. toctree::
140
141 self
142 Contributing <CONTRIBUTING>
143 News <NEWS>
diff --git a/setup.py b/setup.py
index 0bdcee8..f0fe050 100755
--- a/setup.py
+++ b/setup.py
@@ -61,6 +61,9 @@ delegating behavior.
61 'Programming Language :: Python :: 3.7',61 'Programming Language :: Python :: 3.7',
62 'Programming Language :: Python :: 3.8',62 'Programming Language :: Python :: 3.8',
63 ],63 ],
64 extras_require={
65 "docs": ["Sphinx"],
66 },
64 # nose plugins don't really work with `python setup.py test` so use67 # nose plugins don't really work with `python setup.py test` so use
65 # `python setup.py nosetests` instead, or just `tox`. Gosh, we really68 # `python setup.py nosetests` instead, or just `tox`. Gosh, we really
66 # should switch to nose2. :/ - BAW 2014-08-2069 # should switch to nose2. :/ - BAW 2014-08-20
diff --git a/tox.ini b/tox.ini
index 9afcac5..76a9117 100644
--- a/tox.ini
+++ b/tox.ini
@@ -3,3 +3,11 @@ envlist = py27,py32,py33,py34,py35,py36,py37,py38
33
4[testenv]4[testenv]
5commands = python setup.py nosetests5commands = python setup.py nosetests
6
7[testenv:docs]
8basepython =
9 python3
10commands =
11 sphinx-build -b html -d lazr/delegates/docs/_build/doctrees lazr/delegates/docs lazr/delegates/docs/_build/html
12deps =
13 .[docs]

Subscribers

People subscribed via source and target branches

to all changes: