blob: 7ae3f94d7e66af9c438c7f14aa557cc2afa218da (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
#!/bin/bash -x
#--------------------------------------------------------------------------------
# Copyright (c) 2012 CEA LIST.
#
#
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Eclipse Public License v1.0
# which accompanies this distribution, and is available at
# http://www.eclipse.org/legal/epl-v10.html
#
# Contributors:
# Nicolas Bros (Mia-Software)
#--------------------------------------------------------------------------------
cronPromoteScript=/opt/public/modeling/mdt/papyrus/cronPromote.sh
logFile=/opt/public/modeling/mdt/papyrus/log-lastCronPromote
mailRecipients="nbros.mia@gmail.com camille.letavernier@cea.fr patrick.tessier@cea.fr vincent.lorenzo@cea.fr Remi.SCHNEKENBURGER@cea.fr"
bash -x "$cronPromoteScript" 2>&1 | tee "$logFile"
if [ ${PIPESTATUS[0]} != 0 ]; then
echo "promote failed : sending mail"
(echo "This is an automatically generated message sent because the build promotion script 'cronPromote.sh' running on build.eclipse.org failed." &&
echo &&
echo "Run these commands on build.eclipse.org to retry publishing:" &&
echo "--------------------------------------------------------------------------------" &&
echo "cd /opt/public/modeling/mdt/papyrus/" &&
echo "touch papyrus-trunk-nightly/promoteSignal && ./cronPromote.sh # (replace papyrus-trunk-nightly by the job you want to publish)" &&
echo "--------------------------------------------------------------------------------" &&
echo &&
echo &&
echo &&
echo &&
echo &&
cat $logFile) | mail -s "[Papyrus build promotion] build promotion failed" $mailRecipients
fi
|