Skip to content

Commit

Permalink
Test partial clone for github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
7h3kk1d committed Aug 20, 2024
1 parent feb2c5f commit 25b9135
Showing 1 changed file with 29 additions and 24 deletions.
53 changes: 29 additions & 24 deletions .github/workflows/deploy_branches.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,37 +45,42 @@ jobs:
opam exec -- dune build @src/fmt --auto-promote src --profile release
working-directory: ./source
- name: Checkout the website build artifacts repo
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
repository: hazelgrove/build
token: ${{ secrets.ACCESS_TOKEN }}
path: server
sparse-checkout: |
${BRANCH_NAME}
- name: Clear any old build of this branch
run: if [ -d "${BRANCH_NAME}" ] ; then rm -rf "${BRANCH_NAME}" ; fi
working-directory: ./server
- name: Copy in the newly built source
run: mkdir "./server/${BRANCH_NAME}" && cp -r "./source/_build/default/src/haz3lweb/www"/* "./server/${BRANCH_NAME}"
- name : Commit to the website aka deploy
run: |
git config user.name github-deploy-action
git config user.email [email protected]
git add -A
git pull --no-edit
git status
git diff-index --quiet HEAD || (git commit -m "github-deploy-action-${BRANCH_NAME}"; git push)
- name: See the status of the git repo
run: git status
working-directory: ./server
- name: Run Tests
id: test
run: |
eval $(opam env)
make test
working-directory: ./source
- name: Test Report
uses: dorny/test-reporter@v1
with:
name: Test Report
path: junit_tests*.xml
reporter: java-junit
fail-on-error: true
fail-on-empty: true # Use an empty test report to detect when something failed with the test runner
working-directory: ./source
# - name : Commit to the website aka deploy
# run: |
# git config user.name github-deploy-action
# git config user.email [email protected]
# git add -A
# git pull --no-edit
# git status
# git diff-index --quiet HEAD || (git commit -m "github-deploy-action-${BRANCH_NAME}"; git push)
# working-directory: ./server
# - name: Run Tests
# id: test
# run: |
# eval $(opam env)
# make test
# working-directory: ./source
# - name: Test Report
# uses: dorny/test-reporter@v1
# with:
# name: Test Report
# path: junit_tests*.xml
# reporter: java-junit
# fail-on-error: true
# fail-on-empty: true # Use an empty test report to detect when something failed with the test runner
# working-directory: ./source

0 comments on commit 25b9135

Please sign in to comment.