[GSOC 2025]: Github action for translation tracker #4
Workflow file for this run
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: Translation Sync Tracker | |
on: | |
push: | |
branches: [main, week2] | |
paths: | |
- 'src/content/examples/en/**' | |
pull_request: | |
branches: [main, week2] | |
paths: | |
- 'src/content/examples/en/**' | |
workflow_dispatch: | |
inputs: | |
scan_all: | |
description: 'Scan all files instead of just changed files' | |
required: false | |
default: false | |
type: boolean | |
jobs: | |
track-translation-changes: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 2 # Fetch previous commit to compare changes | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '18' | |
- name: Install dependencies | |
run: npm ci | |
- name: Install translation tracker dependencies | |
run: cd .github/actions/translation-tracker && npm install | |
- name: Run translation tracker | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SCAN_ALL: ${{ inputs.scan_all || false }} | |
run: node .github/actions/translation-tracker/index.js |