Skip to content

Sync Meshtastic nodes from online sources #10

Sync Meshtastic nodes from online sources

Sync Meshtastic nodes from online sources #10

name: Sync Meshtastic nodes from online sources
on:
schedule:
# Runs every hour at minute 0
- cron: "0 * * * *"
workflow_dispatch: ~ # Allows manual triggering
permissions:
contents: write
pull-requests: write
jobs:
sync-meshtastic-data:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
token: ${{ secrets.GH_TOKEN }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r meshtastic/nodes/requirements.txt
- name: Run Python script to update Meshtastic nodes data
run: python meshtastic/nodes/sync_nodes.py
--nodes-data-file meshtastic/nodes/nodes.json
- name: Commit data files if modified
uses: EndBug/add-and-commit@v9
with:
add: 'meshtastic'
default_author: github_actions
message: "Meshtastic data updated [skip actions]" # https://github.blog/changelog/2021-02-08-github-actions-skip-pull-request-and-push-workflows-with-skip-ci/
push: '--force'