Skip to content

Commit 8ae5542

Browse files
author
Ralph Castain
committed
Be a little less OMPI-centric on checking for the top-level directory
Look for .git directory Signed-off-by: Ralph Castain <[email protected]>
1 parent fb67c96 commit 8ae5542

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

contrib/update-my-copyright.pl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -120,18 +120,18 @@ sub quiet_print {
120120
$year += 1900;
121121
quiet_print "==> This year: $year\n";
122122

123-
# Find the top-level OMPI source tree dir
123+
# Find the top-level source tree dir in a git repo
124124
my $start = cwd();
125125
my $top = $start;
126-
while (! -f "$top/Makefile.ompi-rules") {
126+
while (! -d "$top/.git") {
127127
chdir("..");
128128
$top = cwd();
129-
die "Can't find top-level Open MPI directory"
129+
die "Can't find top-level repository directory"
130130
if ($top eq "/");
131131
}
132132
chdir($start);
133133

134-
quiet_print "==> Top-level Open MPI dir: $top\n";
134+
quiet_print "==> Top-level repository dir: $top\n";
135135
quiet_print "==> Current directory: $start\n";
136136

137137
# Select VCS used to obtain modification info. Choose in increasing priority

0 commit comments

Comments
 (0)