use uvx
#100
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: CI | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
- name: Install dependencies | |
run: pipx install copier poetry | |
- name: Run test | |
run: | | |
git config --global user.name "GitHub Action" | |
git config --global user.email "action@github.com" | |
copier copy --trust -f -d docker=True -d docs=True . build/ && cd build/ | |
poetry run task lint | |
- name: Push rendered project | |
if: github.ref == 'refs/heads/main' && github.event_name == 'push' | |
run: | | |
REMOTE=https://${GITHUB_ACTOR}:${{ secrets.GH_PAT }}@github.com/${GITHUB_REPOSITORY}.git | |
git -C build push -fu $REMOTE HEAD:rendered |