Skip to content

Commit

Permalink
As23 (#6)
Browse files Browse the repository at this point in the history
* fix

* fix

* fix

* fix

* fix
  • Loading branch information
hosseinmp76 authored Oct 12, 2020
1 parent fcc2de8 commit 999544b
Showing 1 changed file with 29 additions and 8 deletions.
37 changes: 29 additions & 8 deletions .github/workflows/ci-actions.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,27 @@
name: Java CI

on:
push:
branches:
- master
- gthub
on: [push]

jobs:
create_release:
name: Create release
runs-on: ubuntu-latest
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
steps:
- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false

build:
needs: create_release
runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand All @@ -26,7 +40,14 @@ jobs:
restore-keys: ${{ runner.os }}-gradle

- run: ./gradlew runtimeZip
- uses: actions/upload-artifact@v2

- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
name: my-artifact ${{ matrix.os }}
path: build/image.zip
upload_url: ${{ needs.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: build/image.zip
asset_name: my-artifact ${{ matrix.os }}.zip
asset_content_type: application/zip

0 comments on commit 999544b

Please sign in to comment.