IAP GITLAB
Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
corsika
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Air Shower Physics
corsika
Commits
3e6ced5b
Commit
3e6ced5b
authored
4 years ago
by
ralfulrich
Browse files
Options
Downloads
Patches
Plain Diff
improve stability and printout
parent
d156f852
No related branches found
No related tags found
2 merge requests
!234
WIP: Initial example of python as script language from C++
,
!208
Delete AUTHORS file
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
do-copyright.py
+3
-4
3 additions, 4 deletions
do-copyright.py
with
3 additions
and
4 deletions
do-copyright.py
+
3
−
4
View file @
3e6ced5b
...
...
@@ -10,7 +10,6 @@ import re
text
=
"""
/*
* (c) Copyright YEAR CORSIKA Project, corsika-project@lists.kit.edu
*
*
* This software is distributed under the terms of the GNU General Public
* Licence version 3 (GPL Version 3). See file LICENSE for a full version of
* the license.
...
...
@@ -22,7 +21,7 @@ Debug settings are 0: nothing, 1: checking, 2: filesystem
"""
Debug
=
0
excludeDirs
=
[
"
ThirdParty
"
,
"
git
"
]
excludeDirs
=
[
"
ThirdParty
"
,
"
git
"
,
"
build
"
,
"
install
"
]
excludeFiles
=
[
'
PhysicalConstants.h
'
,
'
CorsikaFenvOSX.cc
'
,
'
sgn.h
'
]
extensions
=
[
"
.cc
"
,
"
.h
"
,
"
.test
"
]
...
...
@@ -111,7 +110,7 @@ def checkNote(filename, justCheck, forYear):
if
not
re
.
match
(
regex
,
lines
[
startNote
[
0
]
+
iLine
].
strip
(
"
\n
"
)):
isSame
=
False
foundMissing
=
True
print
(
"
needs update:
"
+
filename
+
"
new=
\'
"
+
noteLines
[
iLine
]
+
"
\'
vs old=
\'
"
+
lines
[
startNote
[
0
]
+
iLine
].
rstrip
(
'
\n
'
)
+
"
\'
"
)
print
(
"
needs update:
"
+
filename
+
"
\n
[diff]
new=
\'
"
+
noteLines
[
iLine
]
+
"
\'
vs old=
\'
"
+
lines
[
startNote
[
0
]
+
iLine
].
rstrip
(
'
\n
'
)
+
"
\'
"
)
break
if
Debug
>
0
:
print
(
"
isSame=
"
+
str
(
isSame
)
+
"
"
+
str
(
len
(
startNote
)))
...
...
@@ -129,7 +128,7 @@ def checkNote(filename, justCheck, forYear):
return
"""
add (new) copyright notice here:
"""
print
(
"
F
ile
:
"
+
filename
+
"
, make copy
to
"
+
filename
+
"
.bak
"
)
print
(
"
[f
ile
]
"
+
filename
+
"
--> backup
to
"
+
filename
+
"
.bak
"
)
os
.
rename
(
filename
,
filename
+
"
.bak
"
)
with
open
(
filename
,
"
w
"
)
as
file
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment