-
Notifications
You must be signed in to change notification settings - Fork 121
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from harishmohanraj/add-ci-workflow
Add workflow file to deploy mintlify docs
- Loading branch information
Showing
1 changed file
with
35 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Deploy Mintlify Website | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- 'autogen/**' | ||
- 'website/**' | ||
- '.github/workflows/deploy-website-mintlify.yml' | ||
|
||
jobs: | ||
deploy-website-mintlify: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
lfs: true | ||
fetch-depth: 0 | ||
|
||
- name: Prepare website content | ||
run: | | ||
# Create a temporary directory for filtered content | ||
mkdir -p temp_website | ||
# Copy all files except .ipynb and node_modules | ||
find website -type f -not -path "*/node_modules/*" -not -name "*.ipynb" -exec cp --parents {} temp_website/ \; | ||
- name: Deploy to mintlify-pages branch | ||
uses: JamesIves/github-pages-deploy-action@v4 | ||
with: | ||
branch: mintlify-pages | ||
folder: temp_website/website | ||
clean: true # Automatically remove deleted files from the deploy branch |