Skip to content

Commit

Permalink
OPHLUDOS-205-1: Remove unpulled commits check
Browse files Browse the repository at this point in the history
Cringe
  • Loading branch information
horttanainen committed Aug 21, 2024
1 parent 0c62b69 commit e7a1b08
Showing 1 changed file with 1 addition and 21 deletions.
22 changes: 1 addition & 21 deletions infra/cdk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,10 @@

source "$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/../scripts/common-functions.sh"



ensure_no_missing_git_commits() {
if [ -n "${SKIP_MISSING_GIT_COMMITS_CHECK:-}" ]; then
echo "Skip checking that all commits in origin/main are present in HEAD"
else
echo "Checking all commits in origin/main are present in HEAD"
git fetch origin main || exit 1
echo
local missing_git_commits
missing_git_commits=$(git log --oneline '^HEAD' 'origin/main')
if [ -n "$missing_git_commits" ]; then
echo "ERROR: origin/main has unpulled commits:"
echo "$missing_git_commits"
exit 1
fi
fi
}

main() {
use_correct_node_version
npm_ci_if_package_lock_has_changed
ensure_no_missing_git_commits
npx cdk --context envName="$ENV" "$@"
}

main "$@"
main "$@"

0 comments on commit e7a1b08

Please sign in to comment.