@@ -224,68 +224,3 @@ jobs:
224224 if : ${{ contains(fromJSON('["schedule", "workflow_dispatch"]'), github.event_name) }}
225225 run : |
226226 git push
227-
228-
229- propagate_translations :
230- runs-on : ubuntu-latest
231- needs : [trigger, update]
232- permissions :
233- contents : read
234- strategy :
235- max-parallel : 4
236- fail-fast : false
237- matrix :
238- branch : ${{fromJson(needs.trigger.outputs.version_pairs)}}
239- language : ${{fromJson(needs.trigger.outputs.languages)}}
240-
241- steps :
242- - name : Check out main
243- uses : actions/checkout@v5
244-
245- - name : Check out branch ${{ matrix.branch.new }}
246- uses : actions/checkout@v5
247- with :
248- ref : ${{ matrix.branch.new }}
249- path : ${{ matrix.branch.new }}
250-
251- - name : Check out branch ${{ matrix.branch.prev }}
252- uses : actions/checkout@v5
253- with :
254- ref : ${{ matrix.branch.prev }}
255- path : ${{ matrix.branch.prev }}
256-
257- - name : Set up Python 3
258- 259- with :
260- python-version : ' 3.12'
261- cache : ' pip'
262- cache-dependency-path : |
263- requirements.txt
264-
265- - name : Install Transifex CLI
266- working-directory : /usr/local/bin
267- run : |
268- curl -o- https://raw.githubusercontent.com/transifex/cli/master/install.sh | bash -s -- v${{ env.TX_CLI_VERSION }}
269-
270- - name : Install dependencies
271- run : |
272- python3 -m pip install --upgrade pip
273- python3 -m pip install pomerge
274-
275- - name : Merge ${{ matrix.language }} translations from ${{ matrix.branch.new }} into ${{ matrix.branch.prev }}
276- run : |
277- if test -d ${{ matrix.branch.prev }}/${{ matrix.language }}; then
278- shopt -s globstar
279- pomerge --from-files ${{ matrix.branch.new }}/${{ matrix.language }}/**/*.po --to-files ${{ matrix.branch.prev }}/${{ matrix.language }}/**/*.po
280- else
281- echo "Branch ${{ matrix.branch.prev }} has no lang code ${{ matrix.language }}."
282- fi
283-
284- - name : Push ${{ matrix.language }} translations for Python ${{ matrix.branch.prev }} documentation to Transifex
285- if : ${{ github.event_name == 'schedule' ||
286- (github.event_name == 'workflow_dispatch' && github.event.inputs.push == 'true') }}
287- working-directory : ${{ matrix.branch.prev }}
288- run : |
289- tx push -t -l ${{ matrix.language }}
290- env :
291- TX_TOKEN : ${{ secrets.TX_TOKEN }}
0 commit comments