Skip to content

Update astral-sh/setup-uv action to v8 (#32) #423

Update astral-sh/setup-uv action to v8 (#32)

Update astral-sh/setup-uv action to v8 (#32) #423

Workflow file for this run

name: Run
on:
push:
branches: [main]
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
jobs:
run:
runs-on: self-hosted
steps:
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: 3.14.4
- uses: actions/setup-node@v6
with:
node-version: 24
- name: Install uv
uses: astral-sh/setup-uv@v8.1.0
- name: Install dependencies
run: |
uv sync --frozen --no-install-project --no-dev --python-preference=only-system
- name: Run Program
run: |
networks=$(paste -sd, networks.txt)
uv run python main.py --search "$networks"
- name: Prettify files
run: |
npx prettier --write .
- name: Check for changes
id: check_changes
run: |
if [[ -z $(git status --porcelain) ]]; then
echo "changes=false" >> $GITHUB_OUTPUT
else
echo "changes=true" >> $GITHUB_OUTPUT
fi
- name: Commit files
if: ${{ steps.check_changes.outputs.changes == 'true' && github.ref == 'refs/heads/main' }}
run: |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add .
git commit -m "Add changes"
- name: Push changes
if: ${{ steps.check_changes.outputs.changes == 'true' && github.ref == 'refs/heads/main' }}
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}