Merge pull request #4 from schauppi/sLSTM #3
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: Update requirements.txt | |
on: | |
push: | |
branches: | |
- '**' | |
paths: | |
- '**/*.py' | |
permissions: write-all | |
jobs: | |
update-requirements: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v4 | |
- name: Set up Python 3.11 | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
- name: Generate requirements.txt | |
run: | | |
pip freeze > requirements.txt | |
- name: Commit and push if changes | |
run: | | |
git config --local user.email "action@github.com" | |
git config --local user.name "GitHub Action" | |
git add requirements.txt | |
git commit -m "Update requirements.txt" -m "Automated update of requirements.txt via GitHub Actions." || echo "No changes to commit" | |
git push |