Skip to content

Update CMEM Plugin List #3

Update CMEM Plugin List

Update CMEM Plugin List #3

name: Update CMEM Plugin List
on:
schedule:
- cron: "0 0 * * *" # Runs daily at midnight UTC
workflow_dispatch: # Allows manual triggering
jobs:
update-plugin-list:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.11
- name: Install dependencies
run: pip install requests beautifulsoup4
- name: Run Python script to query PyPI and update package list
run: |
python src/plugin_info.py # Run the Python script located in 'src/'
- name: Commit and push changes
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
if [[ $(git status --porcelain) ]]; then
git add data/plugins_info.json # Stage the JSON file
git commit -m "Update CMEM plugin information [$(date --utc)]"
git push
else
echo "No changes to commit"
fi