fix: permissions + rename release asset; update README link #2
Workflow file for this run
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: Release on tag (no build) | |
| on: | |
| push: | |
| tags: | |
| - 'v*' # es. v1.0.0, v2025.09 | |
| permissions: | |
| contents: write # NECESSARIO per creare la release e caricare asset | |
| jobs: | |
| release: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| # Se il PDF non è in root, cambia il path (es. docs/main.pdf) | |
| - name: Ensure PDF exists | |
| run: | | |
| if [ ! -f main.pdf ]; then | |
| echo "main.pdf non trovato! Assicurati di committarlo prima di taggare." | |
| exit 1 | |
| fi | |
| # Rinomina l'asset con un nome stabile e SEO-friendly | |
| - name: Rename PDF for release | |
| run: cp main.pdf "appunti-esame-di-stato-ingegneria-informazione.pdf" | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| generate_release_notes: true | |
| files: | | |
| appunti-esame-di-stato-ingegneria-informazione.pdf | |
| # (opzionali) | |
| # draft: false | |
| # prerelease: false | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |