set correct copyright year for all files
This MR sets the correct copyright year (i.e. the year each file was last changed in) for all files.
Merge request reports
Activity
I wrote a script which sets the copyright year in every python file to the year the file was last changed:
#!/usr/bin/env bash while read -rd $'\0' year file; do sed -i "1s/^\(# Copyright \)[[:digit:]]\{4,\}/\1$year/" "$file" done < <(git ls-files -z \*.py | xargs -0I{} git log -1 -z --format="%ad {}" --date="format:%Y" "{}")
I ran the script on the current master working tree. Should I revert the existing commit in this MR and create a new one or amend the changes to the existing commit? And should I add the script to the repository, maybe in the
etc
directory or a newscripts
directory?Edited by Leon Mauritz MöllerI ran the script on the current master working tree. Should I revert the existing commit in this MR and create a new one or amend the changes to the existing commit?
I would amend the exisiting commit and force-push to this existing PR.
And should I add the script to the repository, maybe in the
etc
directory or a newscripts
directory?Hmmm. Why not. I would add it to the
/etc
directory, maybe in some subdirectory like/etc/scripts
.added 7 commits
-
fc92907e...dffc1fa1 - 6 commits from branch
master
- 78d952b0 - set correct copyright year for all files
-
fc92907e...dffc1fa1 - 6 commits from branch
mentioned in commit 3bc00aed