Merge pull request #110 from nrako/add_bsky_reactions #45
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: CI | |
on: | |
push: | |
branches: main | |
pull_request: | |
branches: main | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
steps: | |
- name: Setup repo | |
uses: actions/checkout@v3 | |
- name: Setup Deno | |
uses: denoland/setup-deno@v1 | |
with: | |
deno-version: v2.1.3 | |
- name: Check types | |
run: deno task check | |
- name: Run linter | |
run: deno lint | |
- name: Run tests | |
run: deno test -A --no-check --coverage | |
# run: deno test -A --no-check --coverage | |
# - name: Generate coverage | |
# run: deno coverage --lcov coverage/ > cov.lcov | |
# - name: Upload coverage to Coveralls.io | |
# uses: coverallsapp/github-action@master | |
# with: | |
# github-token: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
# path-to-lcov: cov.lcov | |
deploy: | |
name: Deploy & Lighthouse Check | |
needs: test | |
runs-on: ubuntu-latest | |
permissions: | |
id-token: write # Needed for auth with Deno Deploy | |
contents: read # Needed to clone the repository | |
pull-requests: write | |
statuses: write | |
steps: | |
- name: Clone repository | |
uses: actions/checkout@v4 | |
- name: Install Deno | |
uses: denoland/setup-deno@v1 | |
with: | |
deno-version: v2.x | |
- name: Build step | |
run: 'deno task build' | |
- name: Upload to Deno Deploy | |
id: deploy | |
uses: denoland/deployctl@v1 | |
with: | |
project: 'nrakodotcom' | |
entrypoint: 'main.ts' | |
root: '.' | |
# TODO: Add lighthouse check back | |
# - name: Run Lighthouse CI | |
# uses: treosh/lighthouse-ci-action@v12 | |
# continue-on-error: true | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# DEPLOYMENT_URL: ${{ steps.deploy.outputs.url }} | |
# LHCI_GITHUB_APP_TOKEN: ${{ secrets.LHCI_GITHUB_APP_TOKEN }} | |
# with: | |
# configPath: './lighthouserc.json' | |
# urls: | | |
# ${{ steps.deploy.outputs.url }} | |
# ${{ steps.deploy.outputs.url }}/posts | |
# ${{ steps.deploy.outputs.url }}/posts/hello_web | |
# upoadArtifacts: true | |
# temporaryPublicStorage: true |