TeaCon 甲辰 Sync Pack-building Files #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: TeaCon 甲辰 Sync Pack-building Files | |
on: | |
#push: | |
# paths: | |
# - "jiachen/**" | |
# branches: [ dev ] | |
# tags: '**' | |
workflow_dispatch: | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup profile | |
env: | |
REGION: ${{ secrets.REGION }} | |
ACCESS_KEY: ${{ secrets.TEACON_ARCHIVE_ACCESS_KEY }} | |
SECRET_KEY: ${{ secrets.TEACON_ARCHIVE_SECRET_KEY }} | |
run: aliyun configure set --profile main --region $REGION --mode AK --access-key-id $ACCESS_KEY --access-key-secret $SECRET_KEY | |
- name: Create Resource / Data Pack Archive | |
run: | | |
cd jiachen | |
ls -l | |
zip -qrm TeaCon-JiaChen-Resource.zip assets | |
zip -qu TeaCon-JiaChen-Resource.zip pack.mcmeta | |
zip -qrm TeaCon-JiaChen-Data.zip data | |
zip -qu TeaCon-JiaChen-Data.zip pack.mcmeta | |
ls -l | |
unzip -l TeaCon-JiaChen-Resource.zip | |
unzip -l TeaCon-JiaChen-Data.zip | |
- name: Sync For Test | |
id: sync-test | |
if: ${{ startsWith(github.ref, 'refs/heads') }} | |
env: | |
BUCKET: ${{ secrets.BUCKET }} | |
#run: aliyun oss sync --profile main --delete --force --backup-dir backup ./jiachen/ oss://$BUCKET/jiachen/puer/test/ | |
run: echo 即将到来 | |
- name: Sync For Prod | |
id: sync-prod | |
if: ${{ startsWith(github.ref, 'refs/tags') }} | |
env: | |
BUCKET: ${{ secrets.BUCKET }} | |
#run: aliyun oss sync --profile main --delete --force --backup-dir backup ./jiachen/ oss://$BUCKET/jiachen/puer/prod/ | |
run: echo 即将到来 |