Update CLI Texts #27
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 CLI Texts | |
on: | |
workflow_dispatch: | |
schedule: | |
# Runs every Wednesday at 02:45 AM (UTC) | |
- cron: '45 2 * * 3' | |
permissions: | |
contents: write | |
pull-requests: write | |
jobs: | |
run: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20' | |
- name: Extract CLI texts | |
run: | | |
npm i -g @sap/cds-dk | |
.github/cli/grab-cli-texts.sh | |
- name: Check for changes | |
run: | | |
git config --global user.name 'github-actions[bot]' | |
git config --global user.email 'github-actions[bot]@users.noreply.github.com' | |
if git diff --exit-code; then | |
echo "No changes detected. Exiting." | |
exit 0 | |
fi | |
- name: Create Pull Request | |
uses: peter-evans/create-pull-request@v7 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
branch: "update-cds-cli-texts" | |
commit-message: "Update CLI texts" | |
title: "chore: Update CLI texts" | |
body: "Updates the output of cds CLI texts to the latest version." |