-
-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (66 loc) · 2.08 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: tvtk-auto-update
on:
schedule:
- cron: "0 0 * * *"
push:
branches:
- main
pull_request:
branches:
- main
jobs:
script:
runs-on: ubuntu-latest
steps:
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Get Job URL
uses: Tiryoh/gha-jobid-action@v0
id: jobs
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
job_name: script
- name: checkout with submodule
uses: actions/checkout@v4
with:
persist-credentials: false
submodules: true
token: ${{ secrets.PERSONAL_ACCESSTOKEN }}
- name: Setup SSH
uses: MrSquaare/ssh-setup-action@v3
with:
host: github.com
private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: install
run: |
(cd mayavi; git fetch origin; git checkout main; git reset --hard origin/main; git branch -a)
pip3 install -U pip setuptools
pip3 install -r ./requirements.txt
curl -o- https://raw.githubusercontent.com/transifex/cli/master/install.sh | bash
mv tx /usr/local/bin/tx
- name: update
env:
SPHINXINTL_TRANSIFEX_ORGANIZATION_NAME: tkoyama010
SPHINXINTL_TRANSIFEX_USERNAME: api
SPHINXINTL_TRANSIFEX_PROJECT_NAME: tvtk-doc
TX_TOKEN: ${{ secrets.TX_TOKEN }}
run: |
sh ./locale/update.sh
- name: git_config
run: |
git config --global user.email $GITHUB_REPOSITORY
git config --global user.name $GITHUB_REPOSITORY
- name: commit
if: contains(github.event.head_commit.message, '[ci skip]') == false && contains(github.ref, 'main')
env:
JOB_ID: ${{ steps.jobs.outputs.job_id }}
HTML_URL: ${{ steps.jobs.outputs.html_url }}
run: |
git add .
git commit --allow-empty -m "[ci skip] $JOB_ID
$HTML_URL"
git remote -v
git remote add github [email protected]:$GITHUB_REPOSITORY.git
git push github main