Skip to content

Commit

Permalink
Update action.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
eq19 committed Nov 9, 2024
1 parent bc859d0 commit 78c109c
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 7 deletions.
18 changes: 13 additions & 5 deletions .github/actions/1-addition/3-lexer/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,20 @@ runs:
shell: bash
run: |
TARGET_REPO='https://github.com/${{ env.TARGET_REPOSITORY }}'
git clone --single-branch -b gh-pages ${TARGET_REPO} ${{ inputs.action_path }}/_site &>/dev/null
mv -f ${{ inputs.action_path }}/_site/docs ${RUNNER_TEMP}/
git clone --single-branch -b gh-pages ${TARGET_REPO} ${{ inputs.action_path }}/_site &>/dev/null
cd ${{ inputs.action_path }}/_site && git rm -rfq . && shopt -s dotglob
mv -f ${{ github.workspace }}/_site/* . && rm -rf .devcontainer.json Dockerfile
mv -f ${RUNNER_TEMP}/docs ${{ inputs.action_path }}/_site/
cd ${{ inputs.action_path }}/_site
shopt -s dotglob && rm -rf ${RUNNER_TEMP}/*
[[ -d docs ]] && mv -f docs ${RUNNER_TEMP}/
[[ -d .sass-cache ]] && mv -f .sass-cache ${RUNNER_TEMP}/
[[ -f .jekyll-metadata ]] && mv -f .jekyll-metadata ${RUNNER_TEMP}/
git rm -rfq .
#git clean -fxd && ls -al .
cd ${{ github.workspace }}/_site && rm -rf .git .devcontainer.json Dockerfile
mv -f ${RUNNER_TEMP}/* ${{ inputs.action_path }}/_site/
mv -f * ${{ inputs.action_path }}/_site/
echo 'TARGET_REPOSITORY=${{ env.TARGET_REPOSITORY }}' > ${{ inputs.action_path }}/_site/.env
echo 'LATEST_COMMIT=${{ env.LATEST_COMMIT }}' >> ${{ inputs.action_path }}/_site/.env
Expand Down
7 changes: 6 additions & 1 deletion .github/actions/3-exponentiation/6-grammar/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,13 @@ runs:
- name: ⏪ Rewind all jobs on failure
shell: bash
run: |
if [[ '${{ inputs.failure_status }}' == 'false' ]]; then
if [[ '${{ inputs.failure_status }}' == 'true' ]]; then
git clone --single-branch --branch gh-pages ${{ env.REMOTE_REPO }} gh-pages && cd gh-pages
git add . && git commit --allow-empty -m "rerun due to job failure" && git push
else

cd /home/runner/_site && rm -rf .git .github .env .ssh .cache node-modules
cd ${{ github.workspace }} && git rm -rfq . && shopt -s dotglob && mv -f /home/runner/_site/* .
git add . && git commit --allow-empty -m ${{ env.LATEST_COMMIT }} && git push
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ jobs:

parsering:
needs: lexering
continue-on-error: true
continue-on-error: false
runs-on: ${{ matrix.config.os }}
strategy:
matrix:
Expand Down

0 comments on commit 78c109c

Please sign in to comment.