diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1a42834..12e5ad5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,6 +14,26 @@ jobs: steps: - uses: actions/checkout@v3.3.0 + + - name: JSON to variables + # see https://github.com/antifree/json-to-variables + # You may pin to the exact commit or the version. + # uses: antifree/json-to-variables@cc8c6394031e145c90f7f9ec909d83df92431fb8 + uses: antifree/json-to-variables@v1.2.0 + with: + # The json file. + filename: "./release.json" + # The prefix for variables. + prefix: "mfile" + + - name: "create version.txt" + uses: 1arp/create-a-file-action@0.4.5 + # see https://github.com/marketplace/actions/create-a-file + with: + path: 'src/resources' + isAbsolutePath: false + file: 'version.txt' + content: ${{ env.mfile_version }} - name: Build With Muddler # You may pin to the exact commit or the version. @@ -37,21 +57,10 @@ jobs: # with: # merge-multiple: true - - name: JSON to variables - # see https://github.com/antifree/json-to-variables - # You may pin to the exact commit or the version. - # uses: antifree/json-to-variables@cc8c6394031e145c90f7f9ec909d83df92431fb8 - uses: antifree/json-to-variables@v1.2.0 - with: - # The json file. - filename: "./release.json" - # The prefix for variables. - prefix: "mfile" - - uses: ncipollo/release-action@v1 # see https://github.com/marketplace/actions/create-release with: - artifacts: "build/MUDKIP_Mud2.*,release.json" + artifacts: "build/MUDKIP_Mud2.*,src/resources/version.txt" allowUpdates: true bodyFile: "./README.md" tag: ${{ env.mfile_version }} diff --git a/.gitignore b/.gitignore index 1c7842b..73ca638 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ build/ .output -oldMudletProfile/ \ No newline at end of file +oldMudletProfile/ +src/resources/version.txt