GITBOOK-2191: DOCS-6071: Document OLD_VALUE() function. #63
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: Generate Help Tables SQL | |
| on: | |
| push: | |
| paths: | |
| - 'server/reference/**/*.md' | |
| - 'help-tables/markdown_extractor.py' | |
| pull_request: | |
| paths: | |
| - 'server/reference/**/*.md' | |
| - 'help-tables/markdown_extractor.py' | |
| jobs: | |
| generate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Run generator | |
| run: python help-tables/markdown_extractor.py | |
| - name: Verify output exists | |
| run: | | |
| if [ ! -f help-tables/fill_help_tables.sql ]; then | |
| echo "Error: fill_help_tables.sql was not generated" | |
| exit 1 | |
| fi | |
| echo "Generated $(wc -l < help-tables/fill_help_tables.sql) INSERT statements" | |
| echo "" | |
| echo "=== First 5 statements ===" | |
| head -5 help-tables/fill_help_tables.sql | |
| echo "" | |
| echo "=== Last 5 statements ===" | |
| tail -5 help-tables/fill_help_tables.sql | |
| - name: Validate SQL output | |
| run: python help-tables/validate_sql.py help-tables/fill_help_tables.sql | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fill_help_tables | |
| path: help-tables/fill_help_tables.sql | |
| retention-days: 30 | |
| notify: | |
| runs-on: ubuntu-latest | |
| needs: generate | |
| if: failure() | |
| steps: | |
| - name: Notify Slack on failure | |
| uses: slackapi/slack-github-action@v2.0.0 | |
| with: | |
| webhook: ${{ secrets.SLACK_WEBHOOK_URL }} | |
| webhook-type: incoming-webhook | |
| payload: | | |
| { | |
| "text": "❌ *Help Tables SQL generation failed*\n*Repo:* ${{ github.repository }}\n*Branch:* ${{ github.ref_name }}\n*Commit:* ${{ github.sha }}\n*Pushed by:* ${{ github.actor }}\n*Run:* ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" | |
| } |