From 38208f1c52e45ebed90a308cbe839e0432813795 Mon Sep 17 00:00:00 2001 From: daudix-UFO Date: Mon, 25 Dec 2023 04:42:30 +0300 Subject: [PATCH] chore: Optimize CI --- .woodpecker.yml | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index b9b2984..86afd10 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -24,26 +24,19 @@ steps: image: bitnami/git # Must be set in Woodpecker configuration secrets: [ mail, codeberg_token ] - environment: - - ZOLA_OUTPUT=public commands: # Git configuration - git config --global user.email $MAIL - git config --global user.name "Woodpecker CI" - git clone -b pages https://$CODEBERG_TOKEN@codeberg.org/$CI_REPO.git $CI_REPO_NAME - # Remove old files from repository - - ls # Debug + # Enter repository folder - cd $CI_REPO_NAME - - ls # Debug + # Remove old files from repository folder - git rm -r "*" - - ls # Debug - - cd .. # Copy build step output to repository folder - - cp -ar $ZOLA_OUTPUT/. $CI_REPO_NAME/ - - ls # Debug - # Commit and push all static files with pipeline started timestamp - - cd $CI_REPO_NAME - - git add . + - cp -ar ../public/. $CI_REPO_NAME/ + # Commit and push all static files with source commit SHA + - git add -A - git commit -m "Woodpecker CI ${CI_COMMIT_SHA} [SKIP CI]" - git push when: