Skip to content

Commit

Permalink
chore: update the default api url and add a cache cleanup workflow (#242
Browse files Browse the repository at this point in the history
)
  • Loading branch information
JustAnotherID authored Oct 20, 2024
1 parent e442b79 commit 555e26a
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 1 deletion.
1 change: 1 addition & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
VITE_APP_APIURL="http://localhost:3211"
1 change: 0 additions & 1 deletion .env.development

This file was deleted.

29 changes: 29 additions & 0 deletions .github/workflows/cleanup-caches.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Cleanup Caches from Pull Request
on:
pull_request:
types:
- closed

jobs:
cleanup:
runs-on: ubuntu-latest
steps:
- name: Cleanup
run: |
gh extension install actions/gh-actions-cache
echo "Fetching list of cache key"
cacheKeysForPR=$(gh actions-cache list -R $REPO -B $BRANCH -L 100 | cut -f 1 )
## Setting this to not fail the workflow while deleting cache keys.
set +e
echo "Deleting caches..."
for cacheKey in $cacheKeysForPR
do
gh actions-cache delete $cacheKey -R $REPO -B $BRANCH --confirm
done
echo "Done"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
BRANCH: refs/pull/${{ github.event.pull_request.number }}/merge
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@ stats.html

.idea
/.vscode/settings.json

.env.*

0 comments on commit 555e26a

Please sign in to comment.