Skip to content

Commit

Permalink
updated release action
Browse files Browse the repository at this point in the history
  • Loading branch information
mariotaku committed Jul 17, 2022
1 parent b1a02f6 commit 0ae4696
Showing 1 changed file with 11 additions and 22 deletions.
33 changes: 11 additions & 22 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,8 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Build & Release

on:
push:
branches:
- '!*'
tags:
- 'v*.*'
on:
release:
types: [created]

jobs:
build-and-release:
Expand All @@ -30,25 +24,20 @@ jobs:
- run: npm run package
- run: echo RELEASE_FILENAME_IPK=`ls *.ipk` >> $GITHUB_ENV
- run: npm run manifest
- name: Create Release
id: create_release
uses: actions/create-release@v1

- name: Get release
id: get_release
uses: bruceadams/get-release@v1.2.3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: true
GITHUB_TOKEN: ${{ github.token }}

- name: Upload IPK asset
id: upload-ipk-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.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
upload_url: ${{ steps.get_release.outputs.upload_url }}
asset_path: ${{github.workspace}}/${{env.RELEASE_FILENAME_IPK}}
asset_name: ${{env.RELEASE_FILENAME_IPK}}
asset_content_type: application/vnd.debian.binary-package
Expand All @@ -59,7 +48,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.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
upload_url: ${{ steps.get_release.outputs.upload_url }}
asset_path: ${{github.workspace}}/org.webosbrew.hbchannel.manifest.json
asset_name: org.webosbrew.hbchannel.manifest.json
asset_content_type: application/json
asset_content_type: application/json

0 comments on commit 0ae4696

Please sign in to comment.