various smaller fixes #162
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: cleanup | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
cleanup: | |
runs-on: ubuntu-latest | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v4 | |
# From: https://lannonbr.com/blog/2019-12-09-git-commit-in-actions | |
# setup the username and email. I tend to use 'GitHub Actions Bot' with no email by default | |
- name: setup git config | |
run: | | |
git config user.name "GitHub Actions Bot" | |
git config user.email "<>" | |
- name: Install required packages | |
run: sudo apt install -y dar dar-static par2 git | |
- name: test INC & DIFF cleanup | |
run: | | |
chmod +x $GITHUB_WORKSPACE/test/test-cleanup.sh | |
$GITHUB_WORKSPACE/test/test-cleanup.sh | |
cleanup-alternate-dir: | |
runs-on: ubuntu-latest | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v4 | |
# From: https://lannonbr.com/blog/2019-12-09-git-commit-in-actions | |
# setup the username and email. I tend to use 'GitHub Actions Bot' with no email by default | |
- name: setup git config | |
run: | | |
git config user.name "GitHub Actions Bot" | |
git config user.email "<>" | |
- name: Install required packages | |
run: sudo apt install -y dar dar-static par2 git | |
- name: the test | |
run: | | |
chmod +x $GITHUB_WORKSPACE/test/test-cleanup-alternate-dir.sh | |
$GITHUB_WORKSPACE/test/test-cleanup-alternate-dir.sh | |
cleanup-fail-on-dir-not-found: | |
runs-on: ubuntu-latest | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v4 | |
# From: https://lannonbr.com/blog/2019-12-09-git-commit-in-actions | |
# setup the username and email. I tend to use 'GitHub Actions Bot' with no email by default | |
- name: setup git config | |
run: | | |
git config user.name "GitHub Actions Bot" | |
git config user.email "<>" | |
- name: Install required packages | |
run: sudo apt install -y dar dar-static par2 git | |
- name: the test | |
run: | | |
chmod +x $GITHUB_WORKSPACE/test/test-cleanup-fail-no-dir.sh | |
$GITHUB_WORKSPACE/test/test-cleanup-fail-no-dir.sh | |
cleanup-specific-archive: | |
runs-on: ubuntu-latest | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v4 | |
# From: https://lannonbr.com/blog/2019-12-09-git-commit-in-actions | |
# setup the username and email. I tend to use 'GitHub Actions Bot' with no email by default | |
- name: setup git config | |
run: | | |
git config user.name "GitHub Actions Bot" | |
git config user.email "<>" | |
- name: Install required packages | |
run: sudo apt install -y dar dar-static par2 git | |
- name: the test | |
run: | | |
chmod +x $GITHUB_WORKSPACE/test/test-cleanup-specific-archive.sh | |
$GITHUB_WORKSPACE/test/test-cleanup-specific-archive.sh | |
- name: fail on wrong DIFF_AGE configuration | |
run: | | |
chmod +x $GITHUB_WORKSPACE/test/test-cleanup-fail-diff-age-calc.sh | |
$GITHUB_WORKSPACE/test/test-cleanup-fail-diff-age-calc.sh | |
- name: fail on wrong INC_AGE configuration | |
run: | | |
chmod +x $GITHUB_WORKSPACE/test/test-cleanup-fail-inc-age-calc.sh | |
$GITHUB_WORKSPACE/test/test-cleanup-fail-inc-age-calc.sh |