Update deploy.yaml #14
This file contains 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: Deploy Cobalt | |
on: | |
push: | |
branches: [main] | |
jobs: | |
build-and-deploy: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Download and install Cobalt | |
run: | | |
$cobaltUrl = "https://github.com/cobalt-org/cobalt.rs/releases/download/v0.19.6/cobalt-v0.19.6-x86_64-pc-windows-msvc.zip" | |
Invoke-WebRequest -Uri $cobaltUrl -OutFile "cobalt.zip" | |
Expand-Archive cobalt.zip -DestinationPath "cobalt" | |
echo "$PWD\cobalt" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 | |
shell: pwsh | |
- name: Build the Cobalt site | |
run: cobalt build | |
- name: List files in HTML directory | |
run: dir HTML | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: HTML |