-
Notifications
You must be signed in to change notification settings - Fork 46
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
b57d02f
commit 7c9bff6
Showing
5 changed files
with
20 additions
and
10 deletions.
There are no files selected for viewing
File renamed without changes.
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 |
---|---|---|
|
@@ -21,16 +21,26 @@ jobs: | |
IB_GATEWAY_VER=$(python scripts/detect_ib_gateway_ver.py) | ||
echo ib-gateway-ver=${IB_GATEWAY_VER} >> "$GITHUB_OUTPUT" | ||
python scripts/detect_ibc_ver.py | ||
source .env | ||
git restore .env # restore .env | ||
echo ibc-ver=${IBC_VER} >> "$GITHUB_OUTPUT" | ||
echo ibc-asset-url=${IBC_ASSET_URL} >> "$GITHUB_OUTPUT" | ||
source default.env | ||
if [ "$IB_GATEWAY_VER" = "$CUR_IB_GATEWAY_VER" ]; then | ||
echo "No dated IB gateway version" | ||
echo has_update=false >> "$GITHUB_OUTPUT" | ||
else | ||
echo "New IB gateway version($IB_GATEWAY_VER)" | ||
echo has_update=true >> "$GITHUB_OUTPUT" | ||
fi | ||
if [ "$IBC_VER" = "$CUR_IBC_VER" ]; then | ||
echo "No dated IBC version" | ||
echo has_update=false >> "$GITHUB_OUTPUT" | ||
else | ||
echo "New IBC version($IBC_VER)" | ||
echo has_update=true >> "$GITHUB_OUTPUT" | ||
fi | ||
- name: Update files with new version | ||
if: steps.check-update.outputs.has_update == 'true' | ||
run: | | ||
|
@@ -41,19 +51,21 @@ jobs: | |
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
branch='feat/update-to-${{ steps.check-update.outputs.ib-gateway-ver }}' | ||
branch='feat/update-to-${{ steps.check-update.outputs.ib-gateway-ver }}-ibc${{steps.check-update.outputs.ibc-ver}}' | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git config advice.addIgnoredFile false | ||
git pull | ||
git checkout -b "$branch" origin/develop | ||
# Update files | ||
cp README.update README.md | ||
cp Dockerfile.update Dockerfile | ||
echo "CUR_IB_GATEWAY_VER=${{ steps.check-update.outputs.ib-gateway-ver }}`" > default.env | ||
echo "CUR_IBC_VER=${{ steps.check-update.outputs.ibc-ver }}`" >> default.env | ||
echo "CUR_IB_GATEWAY_VER=${{ steps.check-update.outputs.ib-gateway-ver }}" > .env | ||
echo "CUR_IBC_VER=${{ steps.check-update.outputs.ibc-ver }}" >> .env | ||
##### | ||
git add README.md | ||
git add Dockerfile | ||
git add .env | ||
git commit -m 'Update to `${{ steps.check-update.outputs.ib-gateway-ver }}`' | ||
git push --set-upstream origin "$branch" | ||
|
This file was deleted.
Oops, something went wrong.
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