Skip to content

feat: add github action #37

feat: add github action

feat: add github action #37

Workflow file for this run

name: Deploy GitHub Pages
on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: check if the filter list is uniquely sorted
run: sort -u -c lists/nepali-news-sites.txt
- uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: Build filters
run: deno run -A scripts/build.ts
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4