Skip to content

Commit

Permalink
ci: add GitHub pages release step (#21)
Browse files Browse the repository at this point in the history
  • Loading branch information
isabelroses committed Mar 26, 2024
1 parent 8093e49 commit a749b47
Show file tree
Hide file tree
Showing 2 changed files with 68 additions and 40 deletions.
68 changes: 68 additions & 0 deletions .github/workflows/release-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
name: Release and Deploy

on:
push:
branches: [main]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: denoland/setup-deno@v1
with:
deno-version: v1.x

- run: deno task build

- name: Upload Pages Artifact
uses: "actions/upload-pages-artifact@v3"
with:
path: "dist/"

release:
needs: "build"

runs-on: ubuntu-latest

permissions:
contents: write
pull-requests: write

steps:
- name: "Release"
id: "release"
uses: "google-github-actions/release-please-action@v3"
with:
release-type: "simple"

- name: Create tarball
if: ${{ steps.release.outputs.release_created }}
run: tar czf catppuccin-gitea.tar.gz --directory=./dist .

- name: Upload Release Artifacts
if: ${{ steps.release.outputs.release_created }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh release upload ${{ steps.release.outputs.tag_name }} ./catppuccin-gitea.tar.gz


deploy:
needs: "build"

runs-on: "ubuntu-latest"

permissions:
pages: "write"
id-token: "write"

environment:
name: "github-pages"
url: "${{ steps.deployment.outputs.page_url }}"

steps:
- name: "Deploy to GitHub Pages"
id: "deployment"
uses: "actions/deploy-pages@v4"
40 changes: 0 additions & 40 deletions .github/workflows/release-please.yml

This file was deleted.

0 comments on commit a749b47

Please sign in to comment.