Skip to content

Commit

Permalink
chore: fix bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
teaSummer authored Jun 24, 2024
1 parent e5d7a14 commit 65a6a02
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/launcher.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,14 @@ jobs:
id: get
run: |
# Get Last Stable ${{ matrix.subtitle }}
LAST_STABLE_VERSION=`sed -n '/"${{ matrix.subtitle }}"/,/version:/p' launcher.js | sed -n '$p' | sed 's/^.*:\s"\|",$//gi' | sed 's/\./\\\\./g'`
LAST_STABLE_VERSION=`sed -n '/"${{ matrix.subtitle }}"/,/version:/p' launcher.js | sed -n '$p' | sed 's/^.*:\s*"\|",$//gi' | sed 's/\./\\\\./g'`
# Get Last Dev ${{ matrix.subtitle }}
LAST_DEV_VERSION=`sed -n '/"${{ matrix.subtitle }}"/,/}/p' launcher.js | sed -n '/dev:/,/version:/p' | sed -n '$p' | sed 's/^.*:\s"\|"$//gi' | sed 's/\./\\\\./g'`
LAST_DEV_VERSION=`sed -n '/"${{ matrix.subtitle }}"/,/}/p' launcher.js | sed -n '/dev:/,/version:/p' | sed -n '$p' | sed 's/^.*:\s*"\|"$//gi' | sed 's/\./\\\\./g'`
# GET Latest Stable ${{ matrix.subtitle }}
if [ '${{ matrix.subtitle }}' = HMCL ]; then
LATEST_STABLE_VERSION=`cat releases.json | sed -n '/"tag_name":\s"release-/p' | sed -n 1p | sed 's/^.*release-\|",$//g' | sed 's/\./\\\\./g'`
LATEST_STABLE_VERSION=`cat releases.json | sed -n '/"tag_name":\s*"release-/p' | sed -n 1p | sed 's/^.*release-/release-/g' | sed 's/",$//g' | sed 's/\./\\\\./g'`
else
LATEST_STABLE_VERSION=`cat latest.json | jq .tag_name | sed 's/^"\|"$//gi' | sed 's/\./\\\\./g'`
fi
Expand All @@ -74,7 +74,7 @@ jobs:
# GET Latest Dev ${{ matrix.subtitle }}
if [ "$LAST_DEV_VERSION" ]; then
LATEST_DEV_VERSION=`cat releases.json | sed -n '/"tag_name":/p' | sed -n 1p | sed 's/^.*:\s"\|",$//gi' | sed 's/\./\\\\./g'`
LATEST_DEV_VERSION=`cat releases.json | sed -n '/"tag_name":/p' | sed -n 1p | sed 's/^.*:\s*"\|",$//gi' | sed 's/\./\\\\./g'`
if [ "$LATEST_DEV_VERSION" = "$LATEST_STABLE_VERSION" ]; then
unset LATEST_DEV_VERSION
fi
Expand Down

0 comments on commit 65a6a02

Please sign in to comment.