Merge pull request #1265 from lamby/963124-python-pyqtgraph-please-make-the-build-reproducible

Make the documentation reproducible
This commit is contained in:
Ogi Moore 2020-06-19 22:21:19 -07:00 committed by GitHub
commit f5b8a150c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,6 +11,7 @@
# All configuration values have a default; values that are commented out
# serve to show the default.
import time
import sys
import os
from datetime import datetime
@ -46,7 +47,10 @@ master_doc = 'index'
# General information about the project.
project = 'pyqtgraph'
copyright = '2011 - {}, Luke Campagnola'.format(datetime.now().year)
now = datetime.utcfromtimestamp(
int(os.environ.get('SOURCE_DATE_EPOCH', time.time()))
)
copyright = '2011 - {}, Luke Campagnola'.format(now.year)
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the