diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 536d21d..02d4101 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,7 +9,7 @@ jobs: release: runs-on: ubuntu-latest env: - GRAFANA_API_KEY: $\{{ secrets.GRAFANA_API_KEY }} + GRAFANA_API_KEY: ${{ secrets.GRAFANA_API_KEY }} steps: - uses: actions/checkout@v3 @@ -56,12 +56,12 @@ jobs: - name: Warn missing Grafana API key run: | echo Please generate a Grafana API key: https://grafana.com/docs/grafana/latest/developers/plugins/sign-a-plugin/#generate-an-api-key - echo Once done please follow the instructions found here: https://github.com/$\{{github.repository}}/blob/main/README.md#using-github-actions-release-workflow - if: $\{{ env.GRAFANA_API_KEY == '' }} + echo Once done please follow the instructions found here: https://github.com/${{github.repository}}/blob/main/README.md#using-github-actions-release-workflow + if: ${{ env.GRAFANA_API_KEY == '' }} - name: Sign plugin run: yarn sign - if: $\{{ env.GRAFANA_API_KEY != '' }} + if: ${{ env.GRAFANA_API_KEY != '' }} - name: Get plugin metadata id: metadata @@ -89,15 +89,15 @@ jobs: echo "path=release_notes.md" >> $GITHUB_OUTPUT - name: Check package version - run: if [ "v${{ steps.metadata.outputs.plugin-version }}" != "$\{{ steps.metadata.outputs.github-tag }}" ]; then printf "\033[0;31mPlugin version doesn't match tag name\033[0m\n"; exit 1; fi + run: if [ "v${{ steps.metadata.outputs.plugin-version }}" != "${{ steps.metadata.outputs.github-tag }}" ]; then printf "\033[0;31mPlugin version doesn't match tag name\033[0m\n"; exit 1; fi - name: Package plugin id: package-plugin run: | - mv dist $\{{ steps.metadata.outputs.plugin-id }} - zip $\{{ steps.metadata.outputs.archive }} $\{{ steps.metadata.outputs.plugin-id }} -r - md5sum $\{{ steps.metadata.outputs.archive }} > $\{{ steps.metadata.outputs.archive-checksum }} - echo "checksum=$(cat ./$\{{ steps.metadata.outputs.archive-checksum }} | cut -d' ' -f1)" >> $GITHUB_OUTPUT + mv dist ${{ steps.metadata.outputs.plugin-id }} + zip ${{ steps.metadata.outputs.archive }} ${{ steps.metadata.outputs.plugin-id }} -r + md5sum ${{ steps.metadata.outputs.archive }} > ${{ steps.metadata.outputs.archive-checksum }} + echo "checksum=$(cat ./${{ steps.metadata.outputs.archive-checksum }} | cut -d' ' -f1)" >> $GITHUB_OUTPUT - name: Validate plugin run: | @@ -105,7 +105,7 @@ jobs: pushd ./plugin-validator/pkg/cmd/plugincheck2 go install popd - plugincheck2 -config ./plugin-validator/config/default.yaml $\{{ steps.metadata.outputs.archive }} + plugincheck2 -config ./plugin-validator/config/default.yaml ${{ steps.metadata.outputs.archive }} - name: Create Github release uses: softprops/action-gh-release@v1 @@ -113,19 +113,19 @@ jobs: draft: true generate_release_notes: true files: | - ./$\{{ steps.metadtata.outputs.archive }} - ./$\{{ steps.metadata.outputs.archive-checksum }} + ./${{ steps.metadtata.outputs.archive }} + ./${{ steps.metadata.outputs.archive-checksum }} body: | **This Github draft release has been created for your plugin.** If you would like to submit this release to Grafana please consider the following steps: - - Check the Validate plugin step in the [release wourkflow](https://gihub.com/$\{{github.repository}}/commit/$\{{github.sha}}/checks/$\{{github.run_id}}) for any warnings that need attention + - Check the Validate plugin step in the [release wourkflow](https://gihub.com/${{github.repository}}/commit/${{github.sha}}/checks/${{github.run_id}}) for any warnings that need attention - Navigate to https://grafana.com/auth/sign-in/ to sign into your account - Once logged in click **My Plugins** in the admin navigation - Click the **Submit Plugin** button - Fill in the Plugin Submission form: - - Paste this [.zip asset link](https://github.com/$\{{ github.repository }}/releases/download/v$\{{ steps.metadata.outputs.plugin-version }}/$\{{ steps.metadata.outputs.archive }}) in the Plugin URL field - - Paste this [.zip.md5 link](https://github.com/$\{{ github.repository }}/releases/download/v$\{{ steps.metadata.outputs.glugin-version }}/$\{{ steps.metadata.outputs.archive-checksum }}) in the MD5 field + - Paste this [.zip asset link](https://github.com/${{ github.repository }}/releases/download/v${{ steps.metadata.outputs.plugin-version }}/${{ steps.metadata.outputs.archive }}) in the Plugin URL field + - Paste this [.zip.md5 link](https://github.com/${{ github.repository }}/releases/download/v${{ steps.metadata.outputs.glugin-version }}/${{ steps.metadata.outputs.archive-checksum }}) in the MD5 field Once done please remove these instructions and publish this release.