@@ -22,18 +22,17 @@ jobs:
22
22
runs-on :ubuntu-latest
23
23
steps :
24
24
-name :Check out ${{ github.repository }}
25
- uses :actions/checkout@v3
25
+ uses :actions/checkout@v4
26
26
-name :Check out CPython
27
- uses :actions/checkout@v3
27
+ uses :actions/checkout@v4
28
28
with :
29
29
repository :python/cpython
30
30
persist-credentials :false
31
31
ref :${{ env.CPYTHON_BRANCH }}
32
32
path :cpython
33
33
-name :Set up Python
34
- uses :actions/setup-python@v4
34
+ uses :actions/setup-python@v5
35
35
with :
36
- python-version :' 3.13'
37
36
cache :' pip'
38
37
cache-dependency-path :' **/requirements*.txt'
39
38
-name :Install Transifex CLI
42
41
working-directory :/usr/local/bin
43
42
-name :Install dependencies
44
43
run :|
45
- sudo apt update -y && sudo apt install gettext -y
44
+ sudo apt-get update -y && sudo apt-get install gettext -y
46
45
pip install --upgrade pip
47
46
pip install -r requirements.txt -r cpython/Doc/requirements.txt
48
47
-name :Update translations
@@ -74,52 +73,46 @@ jobs:
74
73
strategy :
75
74
matrix :
76
75
branch :[ "3.13", "3.12", "3.11" ]
77
- include :
78
- -branch :" 3.14"
79
- overwrite :true
76
+
80
77
runs-on :ubuntu-latest
81
78
steps :
82
- -name :Get current branch name
83
- shell :bash
84
- run :
85
- echo "CURRENT_BRANCH=$(echo ${GITHUB_REF#refs/heads/} | tr / -)" >> $GITHUB_ENV
86
- -name :Check out source branch (${{ env.CURRENT_BRANCH }})
87
- uses :actions/checkout@v3
79
+ -name :Check out source branch (${{ env.CPYTHON_BRANCH }})
80
+ uses :actions/checkout@v4
88
81
with :
89
- path :${{ env.CURRENT_BRANCH }}
82
+ path :${{ env.CPYTHON_BRANCH }}
83
+
90
84
-name :Check out target branch (${{ matrix.branch }})
91
- uses :actions/checkout@v3
85
+ uses :actions/checkout@v4
92
86
with :
93
87
ref :${{ matrix.branch }}
94
88
path :${{ matrix.branch }}
89
+
95
90
-name :Set up Python
96
- uses :actions/setup-python@v4
91
+ uses :actions/setup-python@v5
97
92
with :
98
- python-version :' 3.13'
99
93
cache :' pip'
100
94
cache-dependency-path :' **/requirements*.txt'
95
+
101
96
-name :Install dependencies
102
97
run :|
103
- sudo apt update -y && sudo apt install gettext -y
98
+ sudo apt-get update -y && sudo apt-get install gettext -y
104
99
pip install pomerge powrap
100
+
105
101
-name :Merge overwriting on stable release branch
106
- if :${{ matrix.overwrite == true }}
107
- run :|
108
- pomerge --from ${{ env.CURRENT_BRANCH }}/**/*.po --to ${{ matrix.branch }}/**/*.po
109
- -name :Merge without overwriting on EOL or security-fix release branch
110
- if :${{ matrix.overwrite != true }}
111
102
run :|
112
- pomerge --no-overwrite --from ${{ env.CURRENT_BRANCH }}/**/*.po --to ${{ matrix.branch }}/**/*.po
103
+ pomerge --from "${{ env.CPYTHON_BRANCH }}/**/*.po" --to "${{ matrix.branch }}/**/*.po"
104
+
113
105
-name :Wrap catalog message files
114
106
run :|
115
- powrap --modified -C ${{ matrix.branch }}
107
+ powrap --modified -C "${{ matrix.branch }}"
108
+
116
109
-name :Commit and push changes
117
110
if :github.repository == 'python/python-docs-ja'
118
111
run :|
119
- cd ${{ matrix.branch }}
112
+ cd" ${{ matrix.branch }}"
120
113
git config user.name github-actions
121
114
git config user.email github-actions@github.com
122
115
git status
123
116
git add -A
124
- git diff-index --quiet HEAD || ( git commit -m "Merge ${{ env.CURRENT_BRANCH }} into ${{ matrix.branch }}" && git push )
117
+ git diff-index --quiet HEAD || ( git commit -m "Merge ${{ env.CPYTHON_BRANCH }} into ${{ matrix.branch }}" && git push )
125
118