-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Incorporate Russ' suggestions for stable_driver.sh
- Loading branch information
1 parent
33539c7
commit b208ad2
Showing
1 changed file
with
15 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,6 +53,7 @@ repo_url="https://github.com/NOAA-EMC/GDASApp.git" | |
workflow_url="https://github.com/NOAA-EMC/global-workflow.git" | ||
stableroot=$GDAS_CI_ROOT/stable | ||
|
||
[[ -d $stableroot/$datestr ]] && rm -rf $stableroot/$datestr | ||
mkdir -p $stableroot/$datestr | ||
cd $stableroot/$datestr | ||
|
||
|
@@ -63,11 +64,12 @@ git clone --recursive $workflow_url | |
cd $stableroot/$datestr/global-workflow/sorc/gdas.cd | ||
git checkout develop | ||
git pull | ||
git submodule update --init --recursive | ||
|
||
# ============================================================================== | ||
# update the hashes to the most recent | ||
gdasdir=$stableroot/$datestr/global-workflow/sorc/gdas.cd | ||
$my_dir/../ush/submodules/update_develop.sh $gdasdir | ||
$gdasdir/ush/submodules/update_develop.sh $gdasdir | ||
|
||
# ============================================================================== | ||
# run the automated testing | ||
|
@@ -115,19 +117,26 @@ if [ $ci_status -eq 0 ]; then | |
if [ $total -ne 0 ]; then | ||
echo "Unable to push" >> $stableroot/$datestr/output | ||
fi | ||
# send email | ||
PEOPLE="[email protected] [email protected] [email protected] [email protected]" | ||
BODY=$stableroot/$datestr/output_stable_nightly | ||
if [ $total -ne 0 ]; then | ||
echo "Issue merging with develop. please manually fix" | ||
PEOPLE="[email protected] [email protected] [email protected]" | ||
SUBJECT="Problem updating feature/stable-nightly branch of GDASApp" | ||
BODY=$stableroot/$datestr/output_stable_nightly | ||
cat > $BODY << EOF | ||
Problem updating feature/stable-nightly branch of GDASApp. Please check $stableroot/$datestr/GDASApp | ||
EOF | ||
mail -r "Darth Vader - NOAA Affiliate <[email protected]>" -s "$SUBJECT" "$PEOPLE" < $BODY | ||
|
||
else | ||
echo "Stable branch updated" | ||
SUBJECT="Success updating feature/stable-nightly branch of GDASApp" | ||
cat > $BODY << EOF | ||
feature/stable-nightly branch of GDASApp updated successfully. See $stableroot/$datestr/GDASApp for details. | ||
EOF | ||
|
||
fi | ||
echo $SUBJECT | ||
mail -r "Darth Vader - NOAA Affiliate <[email protected]>" -s "$SUBJECT" "$PEOPLE" < $BODY | ||
else | ||
# do nothing | ||
echo "Testing failed, stable branch will not be updated" | ||
|