Skip to content

Update GitHub Release CI #19

Update GitHub Release CI

Update GitHub Release CI #19

Workflow file for this run

name: release
on:
push:
branches: [ main ]
jobs:
overleaf:
name: Release .zip file
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v2
with:
ref: main
persist-credentials: false
- name: Create templates
run: python3 build_release.py
- name: Install zip
run: sudo apt install zip
- name: Zip preamble folder
run: zip -qq -r ./overleaf.zip ./preamble ./template_*.tex
# https://github.community/t/how-can-i-set-an-expression-as-an-environment-variable-at-workflow-level/16516/6
- name: Get current date
id: date
run: echo "::set-output name=date::$(date +'%Y-%m-%d')"
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: v${{ steps.date.outputs.date }}
release_name: Release ${{ steps.date.outputs.date }}
draft: false
prerelease: false
- name: Upload overleaf.zip
id: upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: {{ secrets.GITHUB_TOKEN }}

Check failure on line 48 in .github/workflows/release.yml

View workflow run for this annotation

GitHub Actions / release

Invalid workflow file

The workflow is not valid. .github/workflows/release.yml (Line: 48, Col: 25): A mapping was not expected
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./overleaf.zip
asset_name: overleaf.zip
asset_content_type: application/zip
preamble_only:
name: Update preamble-only branch
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v2
with:
ref: main
persist-credentials: false
- name: Deploy to preamble-only
uses: JamesIves/github-pages-deploy-action@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: preamble-only
folder: preamble