Update oss friends #1412
This file contains hidden or 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 oss friends | |
| on: | |
| push: | |
| branches: | |
| - main | |
| schedule: | |
| - cron: '0 0 * * *' | |
| jobs: | |
| update-file: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@v6 | |
| with: | |
| token: ${{ secrets.TOLGEE_MACHINE_PAT }} | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: "22.x" | |
| - run: corepack enable | |
| - run: npm install | |
| - name: Run your script to update the file | |
| run: npm run oss | |
| - name: Set git globals | |
| run: | | |
| git config --local user.email "machine@tolgee.io" | |
| git config --local user.name "Tolgee Machine" | |
| - name: Check for changes | |
| id: changes | |
| run: | | |
| git add . | |
| git update-index --refresh | |
| CHANGED=$(git diff-index --quiet HEAD --; echo $?) | |
| echo "changed=${CHANGED}" >> $GITHUB_OUTPUT | |
| - name: Commit and push changes | |
| if: steps.changes.outputs.changed == '1' | |
| run: | | |
| git add . | |
| git commit -m "chore: Update oss friends" | |
| git push origin main |