diff --git a/.github/workflows/zenodo-release.yml b/.github/workflows/zenodo-release.yml new file mode 100644 index 0000000..43454a2 --- /dev/null +++ b/.github/workflows/zenodo-release.yml @@ -0,0 +1,29 @@ +name: Zenodo release + +on: + release: + types: [published] + +jobs: + deploy: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + - name: Download archive to runner + env: + tarball: ${{ github.event.release.tarball_url }} + run: | + name=$(basename ${tarball}) + curl -L $tarball > $name + echo "archive=${name}" >> $GITHUB_ENV + + - name: Run Zenodo Deploy + uses: rseng/zenodo-release@main + with: + token: ${{ secrets.ZENODO_TOKEN }} + version: ${{ github.event.release.tag_name }} + zenodo_json: .zenodo.json + archive: ${{ env.archive }} + # TODO: add doi after first released version + #doi: ''