automated release #27
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: automated release | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| tag: | |
| required: true | |
| permissions: | |
| contents: write | |
| jobs: | |
| debug: | |
| name: debug ls | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: debug - ls | |
| run: ls -l | |
| - name: debug - ls (recursive) | |
| run: ls -l -R | |
| release: | |
| name: create release | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: download mpv | |
| run: | | |
| api=$(curl -s "https://api.github.com/repos/shinchiro/mpv-winbuild-cmake/releases/latest" | python -c "import sys, json; print(json.load(sys.stdin)['assets'][11]['browser_download_url'])") | |
| tag=v${{ github.event.inputs.tag }} | |
| echo "api url: $api" | |
| curl -sL "$api" -o mpv.7z | |
| 7z x mpv.7z -ompv/ | |
| rm CODEOWNERS mpv.7z .gitignore README.md mpv/updater.bat | |
| rm -r .git .github mpv/doc mpv/installer | |
| - name: create release | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| tag: v${{ github.event.inputs.tag }} | |
| run: | | |
| zip -r autobloom.zip . | |
| echo "download autobloom from the 'autobloom.zip' file below" | gh release create "$tag" \ | |
| autobloom.zip \ | |
| --repo="$GITHUB_REPOSITORY" \ | |
| --title="autobloom ${tag}" \ | |
| -F - |