summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2017-02-09 12:29:49 -0500
committerJason R. Coombs <jaraco@jaraco.com>2017-02-09 12:29:49 -0500
commite690b031cc3c07b657dc235252a284d8023a38dc (patch)
tree4a5d03360d519981764451206d7ee0784d3f0609
parentee0d8647d8537b9de2aeafeba4acd74910f98a4f (diff)
downloadpytest-runner-e690b031cc3c07b657dc235252a284d8023a38dc.tar.gz
Set the origin date once and forget it.
-rw-r--r--docs/conf.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/docs/conf.py b/docs/conf.py
index 7402c7a..bf6ae64 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -4,6 +4,7 @@
import os
import sys
import subprocess
+import datetime
if 'check_output' not in dir(subprocess):
import subprocess32 as subprocess
@@ -22,7 +23,10 @@ dist_info_cmd = [sys.executable, setup_script] + fields
output_bytes = subprocess.check_output(dist_info_cmd, cwd=root)
project, version, url, author = output_bytes.decode('utf-8').strip().split('\n')
-copyright = '2016 ' + author
+origin_date = datetime.date(2017,1,1)
+today = datetime.date.today()
+
+copyright = '{origin_date.year}-{today.year} {author}'.format(**locals())
# The full version, including alpha/beta/rc tags.
release = version