Update .gitea/workflows/codeant.yml
Some checks failed
Codeant Security Scan / codeant-scan (push) Failing after 15s
Some checks failed
Codeant Security Scan / codeant-scan (push) Failing after 15s
This commit is contained in:
@@ -6,7 +6,7 @@ on:
|
||||
pull_request:
|
||||
branches: ["main"]
|
||||
schedule:
|
||||
- cron: "0 0 * * *" # Daily Scan
|
||||
- cron: "0 0 * * *"
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
@@ -27,15 +27,20 @@ jobs:
|
||||
- name: Install CodeAnt CLI
|
||||
run: npm install -g codeant-cli
|
||||
|
||||
- name: Authenticate CodeAnt
|
||||
run: codeant set-token github ${{ secrets.CODEANT_API_TOKEN }}
|
||||
# ✅ KEEP THIS (correct method)
|
||||
- name: Configure CodeAnt Auth
|
||||
env:
|
||||
CODEANT_API_TOKEN: ${{ secrets.CODEANT_API_TOKEN }}
|
||||
run: |
|
||||
mkdir -p $HOME/.codeant
|
||||
printf '{"apiKey":"%s"}\n' "$CODEANT_API_TOKEN" > $HOME/.codeant/config.json
|
||||
|
||||
- name: Setup Git identity
|
||||
run: |
|
||||
git config --global user.email "ci@gitea.local"
|
||||
git config --global user.name "Gitea CI"
|
||||
|
||||
# 🔥 Full scan only on schedule (recommended)
|
||||
# 🔥 Full scan only on schedule
|
||||
- name: Full repo AI scan (daily)
|
||||
if: github.event_name == 'schedule'
|
||||
run: |
|
||||
@@ -43,7 +48,6 @@ jobs:
|
||||
|
||||
git checkout -b codeant-fullscan || git checkout codeant-fullscan
|
||||
|
||||
# Modify all files to force diff
|
||||
find . -type f \
|
||||
-not -path "./.git/*" \
|
||||
-exec sh -c 'echo "" >> "$1"' _ {} \;
|
||||
@@ -53,12 +57,11 @@ jobs:
|
||||
|
||||
codeant review --committed > review.txt || true
|
||||
|
||||
# ⚡ Normal scan (PR / push)
|
||||
# ⚡ Incremental scan
|
||||
- name: Incremental AI scan
|
||||
if: github.event_name != 'schedule'
|
||||
run: |
|
||||
echo "Running incremental scan..."
|
||||
|
||||
codeant review --committed > review.txt || true
|
||||
|
||||
- name: Show results
|
||||
|
||||
Reference in New Issue
Block a user