diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 812f1cb..5d7bc60 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -22,8 +22,8 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - include: - - {os: ubuntu-latest} + os: + - ubuntu-latest # - {os: macos-12} # - {os: macos-latest} # - {os: windows-latest} @@ -49,5 +49,6 @@ jobs: - uses: arturo-lang/bundler-releases@main with: token: ${{ secrets.GITHUB_TOKEN }} - bundling: ${{ needs.test.outputs }} + name: ${{ needs.test.outputs.EXEFILE }} + version: ${{ needs.test.outputs.VERSION }} \ No newline at end of file diff --git a/action.yml b/action.yml index 85b4f0a..e2eee50 100644 --- a/action.yml +++ b/action.yml @@ -24,12 +24,8 @@ inputs: default: '' release: description: >- - Set to true, if it's running in a release build, to automatically package all assets. + Prepare for release. default: 'false' - release_description: - description: >- - The body for the releases (if `release` is set). If this is not set, then the `github.ref` will be used. - default: '' runs: using: "composite" steps: @@ -75,30 +71,18 @@ runs: fi if [ "${{ inputs.version }}" != "" ]; then - echo "VERS=-${{ inputs.version }}" >> $GITHUB_ENV - echo "VERS=-${{ inputs.version }}" >> $GITHUB_OUTPUT + echo "VERSION=-${{ inputs.version }}" >> $GITHUB_ENV + echo "VERSION=-${{ inputs.version }}" >> $GITHUB_OUTPUT else - echo "VERS=" >> $GITHUB_ENV - echo "VERS=" >> $GITHUB_OUTPUT + echo "VERSION=" >> $GITHUB_ENV + echo "VERSION=" >> $GITHUB_OUTPUT fi if [ "${{ inputs.release }}" = "true" ]; then if [ "${{ inputs.version}}" != "" ]; then ARCHV_VERS=$(arturo --evaluate "print replace {${{ github.ref_name }}} {/^v/} {}") - echo "VERS=$ARCHV_VERS" >> $GITHUB_ENV - fi - - if [ "${{ inputs.release_description }}" = "" ]; then - echo "RELDESC=${{ github.ref }}" >> $GITHUB_ENV - echo "RELDESC=${{ github.ref }}" >> $GITHUB_OUTPUT - else - echo "RELDESC=${{ inputs.release_description }}" >> $GITHUB_ENV - echo "RELDESC=${{ inputs.release_description }}" >> $GITHUB_OUTPUT + echo "VERSION=$ARCHV_VERS" >> $GITHUB_ENV fi - - echo "RELEASE=true" >> $GITHUB_OUTPUT - else - echo "RELEASE=false" >> $GITHUB_OUTPUT fi OSNAMELOWER=$(arturo --evaluate "print lower {${{ runner.os }}}") @@ -118,7 +102,7 @@ runs: - name: Upload Artifact uses: 'actions/upload-artifact@v4' with: - name: ${{ env.EXEFILE }}${{ env.VERS }}-${{ env.ARCHNAME }}-${{ env.OSNAME }} + name: ${{ env.EXEFILE }}${{ env.VERSION }}-${{ env.ARCHNAME }}-${{ env.OSNAME }} path: ${{ env.EXEFILE }}-${{ env.ARCHNAME }}-${{ env.OSNAME }} branding: diff --git a/subaction/action.yml b/subaction/action.yml deleted file mode 100644 index f77589b..0000000 --- a/subaction/action.yml +++ /dev/null @@ -1,53 +0,0 @@ -name: 'Subaction' -description: 'Release Arturo Bundle' -inputs: - token: - description: >- - The GITHUB_TOKEN secret. - required: true - bundling: - description: >- - The architecture to build for. - (one of: 'x86', 'arm', 'arm64', 'amd64', 'native') - required: true -runs: - using: "composite" - steps: - - name: Download Artifact - if: ${{ inputs.bundling.RELEASE == 'true' }} - uses: actions/download-artifact@v2 - with: - path: ./assets - - - name: Create Release - if: ${{ inputs.bundling.RELEASE == 'true' }} - id: create-release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ inputs.token }} - EXEFILE: ${{ needs.test.outputs.EXEFILE }} - VERS: ${{ needs.test.outputs.VERS }} - RELDESC: ${{ needs.test.outputs.RELDESC }} - with: - tag_name: ${{ github.ref_name }} - release_name: "${{ inputs.bundling.EXEFILE }} ${{ inputs.bundling.VERS }}" - body: | - ${{ inputs.bundling.EXEFILE }} ${{ inputs.bundling.VERS }} Release - ${{ inputs.bundling.RELDESC }} - draft: false - prerelease: false - - - name: Upload Release Assets - if: ${{ inputs.bundling.RELEASE == 'true' }} - id: upload-release-assets - uses: dwenegar/upload-release-assets@v1 - env: - GITHUB_TOKEN: ${{ inputs.token }} - with: - release_id: ${{ steps.create-release.outputs.id }} - assets_path: ./assets - -branding: - icon: 'package' - color: 'purple' - \ No newline at end of file