This repository was archived by the owner on Dec 22, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6161 - name : Get New Package Versions From Image
6262 run : |
6363 docker run --rm --entrypoint /bin/sh -v ${PWD}:/tmp vcxpz/ci-build:ci-build -c '\
64- wget -q -O - https://raw.githubusercontent.com/hydazz/docker-utils/main/docker /package_versioner.sh | bash'
64+ wget -q -O - https://raw.githubusercontent.com/hydazz/docker-utils/main/scripts /package_versioner.sh | bash'
6565
6666 - name : Commit and Push Changes to Github
6767 run : |
Original file line number Diff line number Diff line change 1414 - uses : actions/checkout@v2
1515
1616 - name : Clear all workflow runs
17- uses : Mattraks/delete-workflow-runs@main
18- with :
19- token : ${{ secrets.TOKEN }}
20- repository : ${{ github.repository }}
21- retain_days : 1
17+ env :
18+ TOKEN : ${{ secrets.TOKEN }}
19+ run : |
20+ echo "${TOKEN}" | gh auth login --with-token
21+ runs=$(gh api repos/hydazz/docker-amp/actions/runs | jq -r .total_count)
22+ while true; do
23+ if [[ $(gh api repos/hydazz/docker-amp/actions/runs | jq -r .total_count) -gt 2 ]]; then
24+ gh api repos/hydazz/docker-amp/actions/runs \
25+ --paginate -q '.workflow_runs[] | "\(.id)"' | \
26+ xargs -n1 -I % gh api repos/hydazz/docker-amp/actions/runs/% -X DELETE || true
27+ else
28+ exit 0
29+ fi
30+ done
You can’t perform that action at this time.
0 commit comments