Skip to content

Commit

Permalink
Merge branch 'master' of github.com:briandenicola/azure
Browse files Browse the repository at this point in the history
  • Loading branch information
briandenicola committed Jun 20, 2022
2 parents 705bf19 + 858afca commit 0c3161b
Showing 1 changed file with 50 additions and 0 deletions.
50 changes: 50 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: PowerShell Publish Module

on:
workflow_dispatch:
inputs:
tag:
description: 'The Release tag for this run'
required: true
default: '1.0.12'
jobs:
create_release_tag:
runs-on: windows-latest

steps:
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.event.inputs.tag }}
release_name: Release ${{ github.event.inputs.tag }}
draft: false
prerelease: false

outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}

create_release:
needs: create_release_tag
runs-on: windows-latest

steps:
- uses: actions/checkout@v2

- name: Compress module
shell: pwsh
run: |
Compress-Archive -Path bjd.Azure.Functions -DestinationPath bjd.Azure.Functions-${{ github.event.inputs.tag }}.zip
- name: Upload Release Asset
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create_release_tag.outputs.upload_url }}
asset_path: bjd.Azure.Functions-${{ github.event.inputs.tag }}.zip
asset_name: bjd.Azure.Functions-${{ github.event.inputs.tag }}.zip
asset_content_type: application/zip

0 comments on commit 0c3161b

Please sign in to comment.