We want the year in the docs to always be current
(cherry picked from commit f7f7d5c)
This commit is contained in:
parent
9e2e616e1b
commit
017654852d
1 changed files with 6 additions and 2 deletions
|
|
@ -12,6 +12,11 @@
|
|||
# serve to show the default.
|
||||
|
||||
import sys, os
|
||||
import octoprint._version
|
||||
from datetime import date
|
||||
|
||||
year_since = 2013
|
||||
year_current = date.today().year
|
||||
|
||||
# If extensions (or modules to document with autodoc) are in another directory,
|
||||
# add these directories to sys.path here. If the directory is relative to the
|
||||
|
|
@ -42,14 +47,13 @@ master_doc = 'index'
|
|||
|
||||
# General information about the project.
|
||||
project = u'OctoPrint'
|
||||
copyright = u'2013, Gina Häußge'
|
||||
copyright = u'%d-%d, Gina Häußge' % (year_since, year_current) if year_current > year_since else u'%d, Gina Häußge' % year_since
|
||||
|
||||
# The version info for the project you're documenting, acts as replacement for
|
||||
# |version| and |release|, also used in various other places throughout the
|
||||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
import octoprint._version
|
||||
version = octoprint._version.get_versions()["version"]
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = version
|
||||
|
|
|
|||
Loading…
Reference in a new issue