Skip to content

Instantly share code, notes, and snippets.

View stanleegoodspeed's full-sized avatar
🔮
Software Engineer @ Datadog

Colin Cole stanleegoodspeed

🔮
Software Engineer @ Datadog
View GitHub Profile
@stanleegoodspeed
stanleegoodspeed / detect-changes.sh
Last active December 16, 2022 10:37
script to build / tag / push / update docker swarm services that were changed since the last push
#! /bin/bash
# Only process first job in matrix (TRAVIS_JOB_NUMBER ends with ".1")
if [[ ! $TRAVIS_JOB_NUMBER =~ \.1$ ]]; then
echo "Skipping deploy since it's not the first job in matrix"
exit 0
fi
# Don't process pull requests
# $TRAVIS_PULL_REQUEST will be the PR number or "false" if not a PR