Skip to content

Commit

Permalink
Add publising sample on GitHub
Browse files Browse the repository at this point in the history
  • Loading branch information
kant2002 committed Sep 16, 2024
1 parent 6e1f75f commit ffeb8f8
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Docs
on:
push:
branches:
- main
- custom-docs
pull_request:
workflow_dispatch:

Expand All @@ -13,6 +13,13 @@ env:

permissions:
contents: read
pages: write
id-token: write

# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true

jobs:
docs:
Expand Down Expand Up @@ -48,3 +55,21 @@ jobs:
recurse: true
verbosity: error
skip: "^(?!http://localhost)"

- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: ./_site

# Deployment job
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: docs
if: github.event_name != 'pull_request'
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1

0 comments on commit ffeb8f8

Please sign in to comment.