Skip to content

Quarto Publish

Quarto Publish #36

Workflow file for this run

on:
workflow_dispatch:
push:
branches: main
name: Quarto Publish
jobs:
build-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up Quarto
uses: quarto-dev/quarto-actions/setup@v2
- name: Render and Publish
uses: quarto-dev/quarto-actions/publish@v2
with:
target: gh-pages
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
push-to-lrz-gitlab:
needs: build-deploy
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up SSH
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Add GitLab to known hosts
run: |
mkdir -p ~/.ssh
ssh-keyscan gitlab.lrz.de >> ~/.ssh/known_hosts
# You can also verify the fingerprint manually (optional)
# ssh-keyscan gitlab.lrz.de | tee -a ~/.ssh/known_hosts
- name: Check LRZ connection
run: |
ssh -T [email protected]
- name: Add LRZ GitLab remote
run: |
git remote add lrz_gitlab_remote [email protected]:lmu-open-science-center/lmu-osc-website.git
git remote -v
- name: Fetch branches
run: |
git status
git fetch origin gh-pages
git branch
git status
- name: Push branches
run: |
# push them
git push --force lrz_gitlab_remote --gh-pages