ci: added checkout step to workflow
Some checks failed
CI / build-and-publish (push) Has been cancelled

This commit is contained in:
2026-05-12 10:44:44 +03:30
parent b606d5f463
commit bdc7499fc1

View File

@@ -13,6 +13,22 @@ jobs:
shell: sh
steps:
- name: Checkout repository
env:
GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }}
run: |
set -e
apk add --no-cache git
GIT_URL="https://${GITEA_TOKEN}@${GITHUB_SERVER_URL#https://}/${GITHUB_REPOSITORY}.git"
git clone --depth 1 --branch "$GITHUB_REF_NAME" "$GIT_URL" .
if [ "$(git rev-parse HEAD)" != "$GITHUB_SHA" ]; then
echo "Fetching exact commit $GITHUB_SHA..."
git fetch origin "$GITHUB_SHA" --depth 1
git checkout "$GITHUB_SHA"
fi
- name: Install dependencies
run: npm ci --prefer-offline