diff --git a/update.py b/update.py index d9dd5e4..c3964df 100644 --- a/update.py +++ b/update.py @@ -2,6 +2,7 @@ import os import sys +import datetime from collections import OrderedDict, namedtuple # we do not use the nicer sys.version_info.major @@ -113,10 +114,14 @@ def gen_cmake_command(config): def autogenerated_notice(): + start_year = 2015 + year_range = str(start_year) + current_year = datetime.date.today().year + if current_year > start_year: + year_range += '-%s' % current_year s = [] s.append('# This file is autogenerated by Autocmake http://autocmake.org') - s.append('# Copyright (c) 2015 by Radovan Bast and Jonas Juselius') - s.append('# See https://github.com/scisoft/autocmake/') + s.append('# Copyright (c) %s by Radovan Bast and Jonas Juselius' % year_range) return '\n'.join(s) # ------------------------------------------------------------------------------