Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 35 additions & 24 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,27 @@ on:
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10


jobs:

# This workflow contains a single job called "build"
RELEASE_EXTENSION:
strategy:
matrix:
# os: [macos-latest, ubuntu-latest, windows-latest]
os: [ macos-latest, ubuntu-latest ]
# os: [ macos-latest, ubuntu-latest ]
os: [ ubuntu-latest ]
include:
# - os: windows-latest
# script_name: windows
- os: ubuntu-latest
script_name: linux
- os: macos-latest
script_name: osx
# - os: macos-latest
# script_name: osx
runs-on: ${{ matrix.os }}

# Set permissions
permissions:
contents: write
# permissions:
# contents: write

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
Expand All @@ -48,25 +48,36 @@ jobs:
run: |
echo "NATIVE_VERSION=$(echo '${{github.ref}}' | sed -e 's,.*/v\(.*\),\1,')" >> $GITHUB_ENV
shell: bash


# Create Release
- name: Create Release
uses: actions/create-release@latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ github.ref }}
body: "Example body"
draft: true
prerelease: false

# Runs a single command using the runners shell
- name: Run Build
run: |
./gradlew --stacktrace --no-problems-report build -PnativeVersion=${{env.NATIVE_VERSION}}
shell: bash
# - name: Run Build
# run: |
# ./gradlew --stacktrace --no-problems-report build -PnativeVersion=${{env.NATIVE_VERSION}}
# shell: bash

# Generate distro
- name: Create Distro
run: ./gradlew --stacktrace --no-problems-report native-cli:distro -PnativeVersion=${{env.NATIVE_VERSION}}
shell: bash
# - name: Create Distro
# run: ./gradlew --stacktrace --no-problems-report native-cli:distro -PnativeVersion=${{env.NATIVE_VERSION}}
# shell: bash

# Upload the artifact file
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: native-cli/build/distributions/native-cli-${{env.NATIVE_VERSION}}-native-distro-${{ matrix.script_name }}.zip
asset_name: dw-${{env.NATIVE_VERSION}}-${{runner.os}}
tag: ${{ github.ref }}
overwrite: true

# - name: Upload binaries to release
# uses: svenstaro/upload-release-action@v2
# with:
# repo_token: ${{ secrets.GITHUB_TOKEN }}
# file: native-cli/build/distributions/native-cli-${{env.NATIVE_VERSION}}-native-distro-${{ matrix.script_name }}.zip
# asset_name: dw-${{env.NATIVE_VERSION}}-${{runner.os}}
# tag: ${{ github.ref }}
# overwrite: true
Loading