Skip to content

Commit 4af54da

Browse files
committed
fix: cd
1 parent 47472f0 commit 4af54da

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

.github/workflows/release.yml

+8-11
Original file line numberDiff line numberDiff line change
@@ -37,26 +37,23 @@ jobs:
3737
runs-on: ubuntu-latest
3838
steps:
3939
- name: Checkout repository
40-
uses: actions/checkout@v2
40+
uses: actions/checkout@v3
41+
with:
42+
fetch-depth: 0
4143

4244
- name: Check for new commits in the last 23 hours
4345
id: check_commits
4446
run: |
45-
# Get the current time and the time 23 hours ago in ISO 8601 format
46-
now=$(date --utc +%Y-%m-%dT%H:%M:%SZ)
47-
past=$(date --utc --date='23 hours ago' +%Y-%m-%dT%H:%M:%SZ)
48-
49-
# Fetch commit history and check for commits in the last 23 hours
50-
if git rev-list --since="$past" --count HEAD > /dev/null; then
47+
if git log --since="23 hours ago" --oneline | grep -q .; then
5148
echo "New commits found in the last 23 hours."
52-
echo "::set-output name=new_commits::true"
49+
echo "new_commits=true" >> $GITHUB_OUTPUT
5350
else
54-
echo "No new commits found in the last 23 hours."
55-
echo "::set-output name=new_commits::false"
51+
echo "No new commits in the last 23 hours."
52+
echo "new_commits=false" >> $GITHUB_OUTPUT
5653
fi
5754
build:
5855
needs: check_commits
59-
if: ${{ needs.check_commits.outputs.new_commits == 'true' && inputs.track != 'none' }}
56+
if: needs.check_commits.outputs.new_commits == 'true'
6057
name: Build Signed APK
6158
runs-on: ubuntu-latest
6259
env:

0 commit comments

Comments
 (0)