Skip to content

Commit

Permalink
Modified
Browse files Browse the repository at this point in the history
  • Loading branch information
vaisakhkannan committed May 28, 2024
1 parent 67b145c commit e006ba6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/condition.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Fetch All Open Pull Requests using condition using cron job

on:
schedule:
- cron: '50 14 * * 1-5'
- cron: '10 15 * * 1-5'

jobs:
fetch_all_pull_requests_and_notify_using_condition_and_cron:
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/delete_caches.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: cleanup caches by a branch
on:
schedule:
- cron: '46 14 * * 1-5'
- cron: '10 15 * * 1-5'

jobs:
cleanup:
Expand All @@ -13,8 +13,12 @@ jobs:
echo "Fetching list of cache key"
cacheKeysForPR=$(gh actions-cache list -R $REPO -B $BRANCH -L 100 | cut -f 1 )
echo "Cache keys---->: $cacheKeys"


## Setting this to not fail the workflow while deleting cache keys.
## Setting this to not fail the workflow while deleting cache keys.
set +e
echo "Deleting caches..."
for cacheKey in $cacheKeysForPR
Expand All @@ -23,6 +27,6 @@ jobs:
done
echo "Done"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_TOKEN: ${{ secrets.PAT }}
REPO: ${{ github.repository }}
BRANCH: main

0 comments on commit e006ba6

Please sign in to comment.