Update mainaction.yml #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: Download and Merge Zip Files | |
on: [push] | |
jobs: | |
download-and-merge: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Get current date | |
id: date | |
run: echo "::set-output name=date::$(date +'%Y-%m-%d')" | |
- name: Download first zip file | |
run: | | |
curl -L -o trid.zip https://mark0.net/download/trid_w32.zip | |
- name: Download second zip file | |
run: | | |
curl -L -o triddefs.zip https://mark0.net/download/triddefs.zip | |
- name: Unzip first file | |
run: | | |
unzip trid.zip -d extracted1 | |
- name: Unzip second file | |
run: | | |
unzip triddefs.zip -d extracted2 | |
- name: Merge directories | |
run: | | |
mkdir -p merged | |
cp -r extracted1/* merged/ | |
cp -r extracted2/* merged/ | |
- name: Create merged zip file | |
run: | | |
zip -r trid-bundled_${{ steps.date.outputs.date }}.zip merged | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: trid-bundled_${{ steps.date.outputs.date }} | |
path: trid-bundled_${{ steps.date.outputs.date }}.zip |