Update GitHub Actions to use 'download-file' over 'wget'

This commit is contained in:
KingRainbow44 2023-05-15 03:46:23 -04:00
parent 8ecb890fbe
commit 386ad9aa66
No known key found for this signature in database
GPG Key ID: FC2CB64B00D257BE
2 changed files with 24 additions and 11 deletions

View File

@ -38,7 +38,10 @@ jobs:
restore-keys: |
${{ runner.os }}-gradle-
- name: Download Handbook
run: wget https://api.grasscutter.io/static/handbook.html -O src/main/resources/handbook.html
uses: suisei-cn/actions-download-file@v1.4.0
with:
url: https://api.grasscutter.io/static/handbook.html
target: src/main/resources/
- name: Run Gradle
run: ./gradlew && ./gradlew jar
- name: Upload build

View File

@ -43,20 +43,30 @@ jobs:
run: npm run lint
- name: Download Avatar Data
working-directory: src/handbook
run: wget https://api.grasscutter.io/static/avatars.csv -O data/avatars.csv
uses: suisei-cn/actions-download-file@v1.4.0
with:
url: https://api.grasscutter.io/static/avatars.csv
target: src/handbook/data/
- name: Download Command Data
working-directory: src/handbook
run: wget https://api.grasscutter.io/static/commands.json -O data/commands.json
uses: suisei-cn/actions-download-file@v1.4.0
with:
url: https://api.grasscutter.io/static/commands.json
target: src/handbook/data/
- name: Download Entity Data
working-directory: src/handbook
run: wget https://api.grasscutter.io/static/entities.csv -O data/entities.csv
uses: suisei-cn/actions-download-file@v1.4.0
with:
url: https://api.grasscutter.io/static/entities.csv
target: src/handbook/data/
- name: Download Item Data
working-directory: src/handbook
run: wget https://api.grasscutter.io/static/items.csv -O data/items.csv
uses: suisei-cn/actions-download-file@v1.4.0
with:
url: https://api.grasscutter.io/static/items.csv
target: src/handbook/data/
- name: Download Scene Data
working-directory: src/handbook
run: wget https://api.grasscutter.io/static/scenes.csv -O data/scenes.csv
uses: suisei-cn/actions-download-file@v1.4.0
with:
url: https://api.grasscutter.io/static/scenes.csv
target: src/handbook/data/
- run: git config --global user.name "github-actions"
- run: git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"