-
Notifications
You must be signed in to change notification settings - Fork 116
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4e48218
commit 8bb4b72
Showing
1 changed file
with
12 additions
and
15 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 |
---|---|---|
|
@@ -13,13 +13,15 @@ jobs: | |
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Configure Git | ||
run: | | ||
git config --global user.name "XWP Deploy Bot" | ||
git config --global user.email "[email protected]" | ||
- name: Push to xwp/stream-dist | ||
- name: Setup environment | ||
run: | | ||
set -ex | ||
cd $GITHUB_WORKSPACE | ||
# Set up the environment. | ||
ROOT_DIR="$(git rev-parse --show-toplevel)" | ||
WORKING_BRANCH="$(git rev-parse --abbrev-ref HEAD)" | ||
SRC_DIR="$ROOT_DIR/build" | ||
|
@@ -31,28 +33,23 @@ jobs: | |
export GIT_DIR="$DIST_DIR/.git" | ||
export GIT_WORK_TREE="$DIST_DIR" | ||
rm -rf "$SRC_DIR" | ||
rm -rf "$DIST_DIR" | ||
mkdir -p "$SRC_DIR" | ||
- name: Sync files locally | ||
run: | | ||
rsync -av --exclude-from=.distignore "$ROOT_DIR/" "$SRC_DIR/" | ||
- name: Deploy to xwp/stream-dist | ||
run: | | ||
git clone --progress --verbose "$DIST_REPO" "$DIST_DIR/.git" | ||
git checkout -B "$DIST_BRANCH" | ||
# Use the release bundle as the work tree. | ||
export GIT_WORK_TREE="$SRC_DIR" | ||
git config --global user.name "XWP Deploy Bot" | ||
git config --global user.email "[email protected]" | ||
git status | ||
git add --all | ||
git commit --allow-empty --message "$COMMIT_MESSAGE" | ||
# Debug | ||
git log --oneline | ||
ls -al "$SRC_DIR" | ||
ls -al "$DIST_DIR" |