Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Add workflow to publish GitHub pages #2299

Merged
merged 2 commits into from
Aug 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/docs-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Publish Screens landing page
env:
YARN_ENABLE_HARDENED_MODE: 0
on:
push:
branches:
- main
paths: docs/**
workflow_dispatch:

jobs:
publish:
if: github.repository == 'software-mansion/react-native-screens'
runs-on: ubuntu-latest
concurrency:
group: docs-check-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Check out
uses: actions/checkout@v4

- name: Generate landing page content
run: >-
git config --local user.email "action@github.com"
&& git config --local user.name "GitHub Action"
&& cd docs
&& yarn
&& yarn build

- name: Publish generated content to GitHub Pages
uses: JamesIves/github-pages-deploy-action@releases/v3
with:
FOLDER: docs/build
BRANCH: gh-pages
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Empty file added docs/static/.nojekyll
Empty file.
Loading