Skip to content

Commit

Permalink
Adds missing workflow-related file.
Browse files Browse the repository at this point in the history
Signed-off-by: Franco Cipollone <[email protected]>
  • Loading branch information
francocipollone committed Oct 3, 2023
1 parent e6f29e9 commit fca7616
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions .github/try_vcs_checkout
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash
# Copyright 2023 Woven By Toyota

CHANGE_BRANCH=$1
SRC_FOLDER=$2

echo try checking out ${CHANGE_BRANCH}
vcs custom $SRC_FOLDER --args branch -f $CHANGE_BRANCH origin/$CHANGE_BRANCH > /dev/null || true
vcs custom $SRC_FOLDER --args merge --no-edit $CHANGE_BRANCH > /dev/null || true
DIFF=$(vcs diff -s $SRC_FOLDER | tr -d '.\n')
if [ ! -z "$DIFF" ]; then
echo "Have merge conflicts!"
echo $DIFF
exit 1
fi
vcs status $SRC_FOLDER

0 comments on commit fca7616

Please sign in to comment.