feat: replace actions/checkout with manual git clone for Gitea compatibility
Some checks failed
/ audit (push) Failing after 5s
ci-cd / build (push) Failing after 7s
ci / build (push) Failing after 4s
AITBC CLI Level 1 Commands Test / test-cli-level1 (18) (push) Failing after 14s
AITBC CLI Level 1 Commands Test / test-cli-level1 (20) (push) Failing after 5s
autofix / fix (push) Failing after 2s
security-scanning / audit (push) Failing after 2s
test / test (push) Failing after 2s
ci-cd / deploy (push) Has been skipped
Some checks failed
/ audit (push) Failing after 5s
ci-cd / build (push) Failing after 7s
ci / build (push) Failing after 4s
AITBC CLI Level 1 Commands Test / test-cli-level1 (18) (push) Failing after 14s
AITBC CLI Level 1 Commands Test / test-cli-level1 (20) (push) Failing after 5s
autofix / fix (push) Failing after 2s
security-scanning / audit (push) Failing after 2s
test / test (push) Failing after 2s
ci-cd / deploy (push) Has been skipped
BREAKING CHANGE: Replace GitHub Actions checkout with explicit git clone - Remove unreliable actions/checkout@v4 from all workflows - Add manual git clone with HTTPS URL for deterministic behavior - Explicit working directory control with 'cd repo' in each step - Add debug verification steps to confirm repository context - Fix npm install failures by ensuring correct working directory - Update all 7 workflows: ci.yml, audit.yml, fix.yml, test.yml, security-scanning.yml, cli-level1-tests.yml, ci-cd.yml - Use HTTPS clone URL for compatibility with Gitea runners - Add 'rm -rf repo' to ensure clean clone each run This resolves the issue where workflows were executing in hostexecutor directory instead of repository workspace, causing npm install failures.
This commit is contained in:
@@ -6,14 +6,17 @@ on:
|
||||
|
||||
jobs:
|
||||
test:
|
||||
runs-on: debian
|
||||
runs-on: debian
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
- name: Clone repository
|
||||
run: |
|
||||
rm -rf repo
|
||||
git clone https://gitea.bubuit.net/oib/aitbc.git repo
|
||||
|
||||
- name: Verify repository context
|
||||
run: |
|
||||
cd repo
|
||||
echo "Current working directory:"
|
||||
pwd
|
||||
echo "Files in directory:"
|
||||
@@ -21,7 +24,14 @@ jobs:
|
||||
echo "Looking for package.json:"
|
||||
ls -la package.json || echo "package.json not found"
|
||||
|
||||
- run: |
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
cd repo
|
||||
npm install --legacy-peer-deps
|
||||
|
||||
- name: Test runner
|
||||
run: |
|
||||
cd repo
|
||||
echo "Runner OK"
|
||||
hostname
|
||||
whoami
|
||||
|
||||
Reference in New Issue
Block a user