Skip to content

Commit

Permalink
test on pull request.
Browse files Browse the repository at this point in the history
  • Loading branch information
SandPod committed Jan 26, 2024
1 parent 4fc3e29 commit 4b7e71f
Showing 1 changed file with 26 additions and 22 deletions.
48 changes: 26 additions & 22 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Docusaurus deploy
on:
push:
pull_request:
branches:
- main

Expand All @@ -12,34 +12,38 @@ jobs:
runs-on: ubuntu-latest
environment: deploy
steps:
- uses: actions/setup-node@v4
with:
node-version: 18
cache: npm
- name: Checkout docs docs
uses: actions/checkout@v4
- uses: actions/checkout@v4
with:
path: src
- name: Build docs
run: |
cd src
npm ci
npm run build
- name: Checkout target
uses: actions/checkout@v4
# - uses: actions/setup-node@v4
# with:
# node-version: 18
# cache: npm
# cache-dependency-path: src/package-lock.json
# - name: Build docs
# run: |
# cd src
# npm ci
# npm run build
- uses: actions/checkout@v4
with:
path: target
ref: test_deploy_branch
repository: serverpod/serverpod.github.io
ssh-key: ${{ secrets.GH_PAGES_DEPLOY }}
- name: Deploy to target
- name: Display content
run: |
git config --global user.email "[email protected]"
git config --global user.name "serverpod_docs"
cp -r build/* ../target/docs
cd ../target/docs
git add .
git commit -m "Deployed by Serverpod docs deploy action"
git push
ls -la target
cd target
git status
# - name: Deploy to target
# run: |
# git config --global user.email "[email protected]"
# git config --global user.name "serverpod_docs"
# cp -r build/* ../target/docs
# cd ../target
# git add .
# git commit -m "Deployed by Serverpod docs deploy action"
# git push


0 comments on commit 4b7e71f

Please sign in to comment.