@@ -29,7 +29,7 @@ Here you can find a full list of commands: https://github.com/simplelocalize/sim
2929** Required** The version of the SimpleLocalize CLI to use.
3030All available versions can be found here: https://github.com/simplelocalize/simplelocalize-cli/releases
3131
32- Example: ` 2.5.0 `
32+ Example: ` 2.5.1 `
3333
3434### ` args `
3535
4848 push :
4949 branches : [ main ]
5050
51+ env :
52+ cli-version : ' 2.5.1'
53+
5154jobs :
5255 build :
5356 runs-on : ubuntu-latest
5457 steps :
5558 - uses : actions/checkout@v3
59+
5660 - name : Upload translations
5761 uses : simplelocalize/github-action-cli@v2
5862 with :
5963 api-key : ${{ secrets.SIMPLELOCALIZE_API_KEY }}
6064 command : ' upload'
61- cli-version : ' 2.5.0'
62- args : ' --uploadPath ./translations/{lang}.json --uploadFormat single-language-json --dryRun'
65+ cli-version : ${{ env.cli-version }}
66+ args : ' --uploadPath ./translations/{lang}.json --uploadFormat single-language-json'
67+
6368 - name : Auto-translate project
6469 uses : simplelocalize/github-action-cli@v2
6570 with :
6671 api-key : ${{ secrets.SIMPLELOCALIZE_API_KEY }}
6772 command : ' auto-translate'
68- cli-version : ' 2.5.0'
73+ cli-version : ${{ env.cli-version }}
74+
6975 - name : Download translations
7076 uses : simplelocalize/github-action-cli@v2
7177 with :
7278 api-key : ${{ secrets.SIMPLELOCALIZE_API_KEY }}
7379 command : ' download'
74- cli-version : ' 2.5.0 '
80+ cli-version : ${{ env.cli-version }}
7581 args : ' --downloadPath ./translations/{lang}.json --downloadFormat single-language-json'
82+
83+
84+
7685 - name : Publish translations
7786 uses : simplelocalize/github-action-cli@v2
7887 with :
7988 api-key : ${{ secrets.SIMPLELOCALIZE_API_KEY }}
8089 command : ' publish'
81- cli-version : ' 2.5.0'
82- args : ' --environment latest'
90+ cli-version : ${{ env.cli-version }}
91+ args : ' --environment _latest'
92+
8393 - name : Pull translations
8494 uses : simplelocalize/github-action-cli@v2
8595 with :
8696 api-key : ${{ secrets.SIMPLELOCALIZE_API_KEY }}
8797 command : ' pull'
88- cli-version : ' 2.5.0 '
89- args : " --pullPath ./translation-hosting-resources/ --environment latest --filterRegex '_index.json'"
98+ cli-version : ${{ env.cli-version }}
99+ args : " --pullPath ./translation-hosting-resources/ --environment _latest --filterRegex '_index.json'"
90100` ` `
91101
0 commit comments