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
20 changes: 20 additions & 0 deletions .github/actions/create-draft-release-with-assets/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Create draft release with assets
description: Creates a draft GitHub release and attaches asset files found under the given paths
inputs:
asset-paths:
default: 'nugets,assets'
required: false
description: Comma-separated paths where asset files are located
runs:
using: composite
steps:
- name: Create draft release and attach assets
shell: pwsh
run: |
$paths = '${{ inputs.asset-paths }}' -split ',' | ForEach-Object { $_.Trim() }
$assets = (Get-ChildItem -LiteralPath ($paths.Where({Test-Path $_})) -File -Recurse).FullName
Write-Output "Assets to attach: $assets"
Write-Output "Creating draft release for ${{ github.event.repository.name }} ${{ github.ref_name }} at commit ${{ github.sha }}"
gh release create ${{ github.ref_name }} $assets -d -n "<!-- RELEASE PENDING -->" -t "${{ github.ref_name }}"
env:
GH_TOKEN: ${{ github.token }}
Loading