Skip to content

docs: add disk space checks, troubleshooting, update GC section #20

docs: add disk space checks, troubleshooting, update GC section

docs: add disk space checks, troubleshooting, update GC section #20

Workflow file for this run

name: CI
on:
push:
paths:
- 'bin/**'
- 'lib/**'
- 'extras/**'
- 'tests/**'
- 'man/**'
- '.github/workflows/ci.yml'
pull_request:
paths:
- 'bin/**'
- 'lib/**'
- 'extras/**'
- 'tests/**'
- 'man/**'
- '.github/workflows/ci.yml'
jobs:
changes:
runs-on: ubuntu-latest
permissions:
pull-requests: read
outputs:
shell: ${{ steps.filter.outputs.shell }}
python: ${{ steps.filter.outputs.python }}
integration: ${{ steps.filter.outputs.integration }}
man: ${{ steps.filter.outputs.man }}
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: dorny/paths-filter@v4
id: filter
with:
filters: |
shell:
- 'bin/**'
- 'lib/atomic/common.sh'
- 'extras/pacman-wrapper'
- 'tests/test_common.sh'
- '.github/workflows/ci.yml'
python:
- 'lib/atomic/fstab.py'
- 'lib/atomic/rootdev.py'
- 'tests/test_fstab.py'
- 'tests/test_rootdev.py'
- '.github/workflows/ci.yml'
integration:
- 'bin/atomic-guard'
- 'extras/pacman-wrapper'
- 'lib/atomic/common.sh'
- 'etc/atomic.conf'
- 'tests/test_integration.sh'
- '.github/workflows/ci.yml'
man:
- 'man/*.md'
- '.github/workflows/ci.yml'
shellcheck:
needs: changes
if: needs.changes.outputs.shell == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- run: |
shellcheck -s bash -e SC1090,SC1091,SC2010,SC2034 \
bin/atomic-upgrade \
bin/atomic-gc \
bin/atomic-rebuild-uki \
lib/atomic/common.sh \
extras/pacman-wrapper
shellcheck -s bash -e SC1090,SC1091,SC2310 \
bin/atomic-guard
python-lint:
needs: changes
if: needs.changes.outputs.python == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- run: pip install --no-cache-dir ruff mypy
- run: ruff check lib/atomic/fstab.py lib/atomic/rootdev.py
- run: mypy --ignore-missing-imports lib/atomic/fstab.py lib/atomic/rootdev.py
python-test:
needs: changes
if: needs.changes.outputs.python == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- run: pip install --no-cache-dir pytest
- run: python -m pytest tests/ -v
bash-test:
needs: changes
if: needs.changes.outputs.shell == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- run: bash tests/test_common.sh
integration-test:
needs: changes
if: needs.changes.outputs.integration == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- run: bash tests/test_integration.sh
man-check:
needs: changes
if: needs.changes.outputs.man == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install pandoc
run: sudo apt-get update && sudo apt-get install -y pandoc
- name: Regenerate man pages
run: make man
- name: Check groff files are up to date
run: |
if ! git diff --quiet man/; then
echo "::error::Man pages are out of date. Run 'make man' and commit the results."
git diff man/
exit 1
fi