Skip to content

Commit 4a798d5

Browse files
committed
The script generate-docker-library.sh take in charge the 'latest' to tag the last new version of Silverpeas
1 parent 43daef4 commit 4a798d5

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

generate-docker-library.sh

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,21 @@ Maintainers: Miguel Moquillon <miguel.moquillon@silverpeas.org> (@mmoqui)
66
GitRepo: https://github.com/Silverpeas/docker-silverpeas-prod.git
77
EOH
88

9-
for version in `git tag | tac | grep "^[0-9.]\+$"`; do
10-
commit=`git rev-parse ${version}`
9+
function printVersion() {
1110
cat <<-EOE
1211
13-
Tags: ${version}
14-
GitCommit: ${commit}
12+
Tags: $1
13+
GitCommit: $2
1514
EOE
16-
done
15+
}
16+
17+
isFirst=1
18+
for version in `git tag | tac | grep "^[0-9.]\+$"`; do
19+
commit=`git rev-parse ${version}`
20+
if [ $isFirst -eq 1 ]; then
21+
isFirst=0
22+
printVersion "${version}, latest" ${commit}
23+
else
24+
printVersion "${version}" ${commit}
25+
fi
26+
done

0 commit comments

Comments
 (0)