Skip to content

Commit

Permalink
Add release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
julienduchesne committed Nov 28, 2022
1 parent 67fffbd commit d8f7c4c
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Releases

on:
push:
tags:
- 'v*'

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v2
- run: ./hack/merge-crds.sh
- uses: ncipollo/release-action@v1
with:
allowUpdates: true
artifacts: "dist/*"
body: "See https://marketplace.upbound.io/providers/grafana/provider-grafana/ for API documentation."
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@ cover.out
# ignore IDE folders
.vscode/
.idea/

# ignore build artifacts
dist/crds.yaml
9 changes: 9 additions & 0 deletions hack/merge-crds.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#! /usr/bin/env bash
set -euox pipefail

mkdir -p dist
rm -f dist/crds.yaml

for f in $(ls package/crds/*.yaml); do
cat "$f" >> dist/crds.yaml
done

0 comments on commit d8f7c4c

Please sign in to comment.