diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml new file mode 100644 index 0000000..aa0c71a --- /dev/null +++ b/.github/workflows/sync.yml @@ -0,0 +1,62 @@ +name: Sync PHP Package Versions +permissions: + contents: write +on: + workflow_dispatch: + workflow_call: + schedule: + - cron: "20 4 * * *" + +jobs: + run: + runs-on: ubuntu-latest + name: PHP ${{ matrix.php-versions }} + strategy: + matrix: + operating-system: ['ubuntu-latest'] + php-versions: + - '7.4' + - '8.0' + - '8.1' + - '8.2' + - '8.3' + steps: + - uses: actions/checkout@v4 + + - name: "PHP 8.3" + run: | + php generate.php ${{ matrix.php-versions }} + + - name: List dirs + run: find data | sed -e "s/[^-][^\/]*\// |/g" -e "s/|\([^ ]\)/|-\1/" + +# collect: +# needs: run +# runs-on: ubuntu-latest +# name: Collect and Commit Data +# permissions: +# contents: write +# +# steps: +# - uses: actions/checkout@v4 +# name: Checkout main repo +# +# +# - name: Prime files +# run: | +# cp scratch/* data/ -Rf +# +# - name: List dirs +# run: find data | sed -e "s/[^-][^\/]*\// |/g" -e "s/|\([^ ]\)/|-\1/" +# +# - name: Generate commit message +# id: commit_msg +# run: echo "commit_msg=$(date +"%Y %b %d")" >> "$GITHUB_OUTPUT" +# +# - name: Commit data +# uses: stefanzweifel/git-auto-commit-action@v5 +# with: +# commit_message: ${{ steps.commit_msg.outputs.commit_msg }} +# branch: main +# repository: data +# add_options: '-A'