Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
3nids committed Feb 19, 2024
1 parent 8f88c23 commit 65779cd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ on:
- 'website/**'
- '.github/workflows/website.yml'
workflow_dispatch: # useful for testing tx pushes
workflow_call:

permissions:
contents: write
Expand Down Expand Up @@ -67,22 +66,22 @@ jobs:
TX_TOKEN: ${{ secrets.TX_TOKEN }}

- name: Pull translations from Transifex
if: ${{ github.event_name == 'push' || github.event.pull_request.head.repo.full_name == 'opengisch/signalo' && github.actor != 'dependabot[bot]' }}
if: ${{ github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event.pull_request.head.repo.full_name == 'opengisch/signalo' && github.actor != 'dependabot[bot]' }}
run: |
./tx pull --translations --all --minimum-perc 10
./tx status
env:
TX_TOKEN: ${{ secrets.TX_TOKEN }}

- name: Translate Mkdocs config
if: ${{ github.event_name == 'push' || github.event.pull_request.head.repo.full_name == 'opengisch/signalo' && github.actor != 'dependabot[bot]' }}
if: ${{ github.event_name == 'push' || github.event_name == 'workflow_dispatch' || github.event.pull_request.head.repo.full_name == 'opengisch/signalo' && github.actor != 'dependabot[bot]' }}
run: |
./scripts/mkdocs_tx.py -s fr update_config
./scripts/mkdocs_tx_commit.sh
env:
GITHUB_HEADREF: ${{ github.head_ref }}
GITHUB_EVENT: ${{ github.event_name }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GEONINJA_PAT }}

- name: Build documentation
run: mkdocs build
Expand Down
3 changes: 0 additions & 3 deletions website/scripts/mkdocs_tx_commit.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
#!/usr/bin/env bash

if [[ $(git diff --exit-code mkdocs.yml) ]]; then
git config --global user.email "bot@opengis.ch"
git config --global user.name "OPENGIS.ch Bot"

echo "detected changes in mkdocs.yml"
if [[ ${GITHUB_EVENT} == "pull_request" ]]; then
# on PR push to the same branch
Expand Down

0 comments on commit 65779cd

Please sign in to comment.