agentplugged 1.3.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -4
- package/dist/agent-commands.js +20432 -35457
- package/dist/bin.js +2 -3
- package/dist/boundary-rules.js +1 -0
- package/dist/boundary-rules2.js +52 -0
- package/dist/cli.js +7 -3
- package/dist/commit-documents.js +81 -0
- package/dist/dist.js +22729 -0
- package/dist/dist2.js +9 -0
- package/dist/esm.js +8 -16
- package/dist/forge-follow.js +6 -7
- package/dist/grammars/LICENSE-tree-sitter-wasm +21 -0
- package/dist/grammars/LICENSE-web-tree-sitter +21 -0
- package/dist/grammars/tree-sitter-go.wasm +0 -0
- package/dist/grammars/tree-sitter-java.wasm +0 -0
- package/dist/grammars/tree-sitter-javascript.wasm +0 -0
- package/dist/grammars/tree-sitter-php.wasm +0 -0
- package/dist/grammars/tree-sitter-python.wasm +0 -0
- package/dist/grammars/tree-sitter-rust.wasm +0 -0
- package/dist/grammars/tree-sitter-tsx.wasm +0 -0
- package/dist/grammars/tree-sitter-typescript.wasm +0 -0
- package/dist/grammars/web-tree-sitter.wasm +0 -0
- package/dist/hash.js +11594 -5733
- package/dist/helpers.js +271 -519
- package/dist/launcher-env.js +1 -2
- package/dist/launcher.js +4 -5
- package/dist/libsodium-wrappers.js +2 -4
- package/dist/libsodium-wrappers2.js +2 -4
- package/dist/main.js +10502 -2787
- package/dist/map-cache.js +8096 -0
- package/dist/map-update.js +16593 -0
- package/dist/map-update2.js +1 -0
- package/dist/method/agents/alex/SKILL.md +13 -29
- package/dist/method/agents/alex/agent.yaml +3 -3
- package/dist/method/agents/basile/SKILL.md +44 -0
- package/dist/method/agents/basile/agent.yaml +69 -0
- package/dist/method/agents/chloe/SKILL.md +12 -25
- package/dist/method/agents/chloe/agent.yaml +3 -3
- package/dist/method/agents/ethan/SKILL.md +8 -9
- package/dist/method/agents/ethan/agent.yaml +9 -8
- package/dist/method/agents/hugo/SKILL.md +8 -8
- package/dist/method/agents/hugo/agent.yaml +9 -8
- package/dist/method/agents/iris/SKILL.md +11 -17
- package/dist/method/agents/iris/agent.yaml +4 -7
- package/dist/method/agents/izzy/SKILL.md +68 -91
- package/dist/method/agents/izzy/agent.yaml +8 -15
- package/dist/method/agents/jade/SKILL.md +7 -9
- package/dist/method/agents/jade/agent.yaml +9 -8
- package/dist/method/agents/julien/SKILL.md +38 -58
- package/dist/method/agents/lina/SKILL.md +7 -9
- package/dist/method/agents/lina/agent.yaml +9 -8
- package/dist/method/agents/lou/SKILL.md +4 -11
- package/dist/method/agents/lou/agent.yaml +2 -2
- package/dist/method/agents/maya/SKILL.md +12 -19
- package/dist/method/agents/maya/agent.yaml +2 -4
- package/dist/method/agents/milo/SKILL.md +21 -32
- package/dist/method/agents/noah/SKILL.md +105 -63
- package/dist/method/agents/noah/agent.yaml +15 -35
- package/dist/method/agents/noah/evals/routes.yaml +238 -0
- package/dist/method/agents/noah/references/decisions.md +59 -121
- package/dist/method/agents/noah/references/environment.md +25 -70
- package/dist/method/agents/noah/references/facts.md +22 -11
- package/dist/method/agents/noah/references/journey.md +26 -78
- package/dist/method/agents/noah/references/team.md +67 -190
- package/dist/method/agents/omar/SKILL.md +14 -30
- package/dist/method/agents/omar/agent.yaml +12 -6
- package/dist/method/agents/quentin/SKILL.md +7 -15
- package/dist/method/agents/quentin/agent.yaml +4 -2
- package/dist/method/agents/sam/SKILL.md +6 -8
- package/dist/method/agents/sam/agent.yaml +9 -8
- package/dist/method/agents/stella/SKILL.md +6 -14
- package/dist/method/agents/stella/agent.yaml +1 -1
- package/dist/method/agents/tess/SKILL.md +7 -14
- package/dist/method/agents/tess/agent.yaml +2 -2
- package/dist/method/agents/zoe/SKILL.md +9 -21
- package/dist/method/doctor.yaml +553 -13
- package/dist/method/models.yaml +12 -0
- package/dist/method/skills/acceptance-qa/SKILL.md +1 -1
- package/dist/method/skills/acceptance-qa/references/run.md +24 -32
- package/dist/method/skills/acceptance-qa/references/scenarios.md +16 -19
- package/dist/method/skills/acceptance-qa/references/verdicts.md +10 -16
- package/dist/method/skills/api-e2e-tests/SKILL.md +46 -46
- package/dist/method/skills/audit-pillars/SKILL.md +13 -10
- package/dist/method/skills/audit-pillars/references/demo.md +35 -0
- package/dist/method/skills/audit-pillars/references/pillars.md +40 -0
- package/dist/method/skills/audit-pillars/references/tech-debt.md +38 -0
- package/dist/method/skills/chain-stories/SKILL.md +5 -4
- package/dist/method/skills/chain-stories/references/merge-order.md +23 -0
- package/dist/method/skills/check-readiness/SKILL.md +1 -1
- package/dist/method/skills/check-requirements/SKILL.md +37 -72
- package/dist/method/skills/check-requirements/references/engine-proofs.md +16 -23
- package/dist/method/skills/check-requirements/references/proofs-and-gaps.md +22 -37
- package/dist/method/skills/critique-deliverable/SKILL.md +3 -3
- package/dist/method/skills/critique-deliverable/references/choose.md +12 -21
- package/dist/method/skills/critique-deliverable/references/format.md +14 -20
- package/dist/method/skills/critique-deliverable/references/gestures.md +14 -21
- package/dist/method/skills/critique-deliverable/references/judgment.md +4 -9
- package/dist/method/skills/critique-deliverable/references/methods.md +21 -0
- package/dist/method/skills/critique-deliverable/references/reconcile.md +6 -11
- package/dist/method/skills/deep-research/SKILL.md +16 -24
- package/dist/method/skills/deep-research/references/candidates.md +13 -25
- package/dist/method/skills/deep-research/references/external.md +15 -34
- package/dist/method/skills/deep-research/references/page-format.md +16 -42
- package/dist/method/skills/deep-research/references/types.md +16 -27
- package/dist/method/skills/develop-story/SKILL.md +56 -189
- package/dist/method/skills/develop-story/references/acceptance-tests.md +18 -71
- package/dist/method/skills/develop-story/references/quick-lane.md +20 -0
- package/dist/method/skills/diagnose-bug/SKILL.md +42 -53
- package/dist/method/skills/diagnose-bug/references/hypotheses.md +1 -2
- package/dist/method/skills/generate-knowledge-base/SKILL.md +57 -226
- package/dist/method/skills/generate-knowledge-base/assets/index-template.md +6 -15
- package/dist/method/skills/generate-knowledge-base/assets/page-template.md +11 -24
- package/dist/method/skills/generate-knowledge-base/references/living-docs.md +25 -64
- package/dist/method/skills/generate-knowledge-base/references/reuse-map.md +9 -18
- package/dist/method/skills/ideation/SKILL.md +16 -23
- package/dist/method/skills/ideation/references/close.md +18 -14
- package/dist/method/skills/ideation/references/converge.md +11 -21
- package/dist/method/skills/ideation/references/stances.md +13 -17
- package/dist/method/skills/ideation/references/techniques.md +20 -0
- package/dist/method/skills/improve-code/SKILL.md +42 -54
- package/dist/method/skills/pitch/SKILL.md +16 -19
- package/dist/method/skills/pitch/references/deck.md +15 -18
- package/dist/method/skills/pitch/references/design-implementation.md +13 -21
- package/dist/method/skills/pitch/references/design.md +21 -0
- package/dist/method/skills/pitch/references/story.md +13 -18
- package/dist/method/skills/plan-sprint/SKILL.md +50 -151
- package/dist/method/skills/plan-sprint/references/rituals.md +40 -0
- package/dist/method/skills/prepare-go-live/SKILL.md +59 -0
- package/dist/method/skills/resolve-merge-conflict/SKILL.md +40 -65
- package/dist/method/skills/review-after-launch/SKILL.md +56 -0
- package/dist/method/skills/review-story/SKILL.md +44 -72
- package/dist/method/skills/review-story/references/amend-story.md +8 -13
- package/dist/method/skills/review-story/references/export.md +7 -17
- package/dist/method/skills/review-story/references/free-review.md +9 -20
- package/dist/method/skills/review-story/references/judge.md +25 -37
- package/dist/method/skills/review-story/references/tests.md +29 -0
- package/dist/method/skills/run-acceptance/SKILL.md +58 -0
- package/dist/method/skills/run-acceptance/references/template.md +39 -0
- package/dist/method/skills/run-retrospective/SKILL.md +50 -189
- package/dist/method/skills/security-review-architecture/SKILL.md +46 -109
- package/dist/method/skills/security-review-architecture/references/spec-review.md +27 -38
- package/dist/method/skills/setup-ci/SKILL.md +46 -109
- package/dist/method/skills/setup-ci/assets/access-check.mjs +116 -0
- package/dist/method/skills/setup-ci/assets/security-github.yml +41 -0
- package/dist/method/skills/setup-ci/assets/security-gitlab.yml +22 -0
- package/dist/method/skills/setup-ci/assets/stack-dotnet-github.yml +118 -0
- package/dist/method/skills/setup-ci/assets/stack-dotnet-gitlab.yml +63 -0
- package/dist/method/skills/setup-ci/assets/stack-go-github.yml +118 -0
- package/dist/method/skills/setup-ci/assets/stack-go-gitlab.yml +63 -0
- package/dist/method/skills/setup-ci/assets/stack-jvm-gradle-github.yml +134 -0
- package/dist/method/skills/setup-ci/assets/stack-jvm-gradle-gitlab.yml +71 -0
- package/dist/method/skills/setup-ci/assets/stack-jvm-maven-github.yml +133 -0
- package/dist/method/skills/setup-ci/assets/stack-jvm-maven-gitlab.yml +70 -0
- package/dist/method/skills/setup-ci/assets/stack-python-github.yml +123 -0
- package/dist/method/skills/setup-ci/assets/stack-python-gitlab.yml +68 -0
- package/dist/method/skills/setup-ci/assets/stack-rust-github.yml +107 -0
- package/dist/method/skills/setup-ci/assets/stack-rust-gitlab.yml +64 -0
- package/dist/method/skills/setup-ci/references/security.md +39 -0
- package/dist/method/skills/setup-ci/references/stacks.md +22 -0
- package/dist/method/skills/split-into-stories/SKILL.md +59 -192
- package/dist/method/skills/split-into-stories/assets/story.md.tmpl +15 -4
- package/dist/method/skills/strategy/SKILL.md +20 -25
- package/dist/method/skills/strategy/references/costs.md +12 -26
- package/dist/method/skills/strategy/references/gestures.md +12 -21
- package/dist/method/skills/strategy/references/innovate.md +19 -37
- package/dist/method/skills/strategy/references/solve.md +19 -32
- package/dist/method/skills/test-idea/SKILL.md +5 -5
- package/dist/method/skills/test-idea/assets/prfaq-template.md +1 -1
- package/dist/method/skills/test-idea/references/faq.md +12 -29
- package/dist/method/skills/test-idea/references/forge.md +19 -30
- package/dist/method/skills/test-idea/references/personas.md +16 -19
- package/dist/method/skills/test-idea/references/prfaq.md +31 -31
- package/dist/method/skills/workshop/SKILL.md +10 -16
- package/dist/method/skills/workshop/references/create.md +28 -45
- package/dist/method/skills/workshop/references/customize.md +17 -42
- package/dist/method/skills/workshop/references/evaluate.md +11 -42
- package/dist/method/skills/workshop/references/rules.md +17 -26
- package/dist/method/skills/write-architecture/SKILL.md +62 -220
- package/dist/method/skills/write-architecture/references/guard.md +12 -27
- package/dist/method/skills/write-architecture/references/self-check.md +22 -38
- package/dist/method/skills/write-brand/SKILL.md +2 -2
- package/dist/method/skills/write-brand/references/identity.md +21 -22
- package/dist/method/skills/write-brand/references/platform.md +13 -20
- package/dist/method/skills/write-brand/references/rules.md +16 -22
- package/dist/method/skills/write-brief/SKILL.md +55 -149
- package/dist/method/skills/write-brief/assets/brief-template.md +7 -5
- package/dist/method/skills/write-brief/references/brief-checklist.md +18 -30
- package/dist/method/skills/write-content/SKILL.md +53 -210
- package/dist/method/skills/write-content/references/content-checklist.md +32 -50
- package/dist/method/skills/write-positioning/SKILL.md +53 -197
- package/dist/method/skills/write-positioning/references/positioning-checklist.md +15 -41
- package/dist/method/skills/write-positioning/references/seo-checklist.md +26 -51
- package/dist/method/skills/write-prd/SKILL.md +52 -179
- package/dist/method/skills/write-prd/references/prd-checklist.md +25 -54
- package/dist/method/skills/write-sales/SKILL.md +48 -212
- package/dist/method/skills/write-sales/references/before-you-send.md +21 -49
- package/dist/method/skills/write-sales/references/sales-checklist.md +19 -69
- package/dist/method/skills/write-spec/references/spec-guide.md +20 -23
- package/dist/method/skills/write-ux-spec/SKILL.md +57 -168
- package/dist/method/skills/write-ux-spec/references/accessibility-check.md +13 -72
- package/dist/method/skills/write-ux-spec/references/mockups.md +6 -68
- package/dist/method/skills/write-ux-spec/references/tokens-and-sketches.md +8 -81
- package/dist/method/skills/write-ux-spec/references/ux-checklist.md +12 -67
- package/dist/product-root.js +96 -20743
- package/dist/project-command.js +776 -0
- package/dist/project-command2.js +1 -0
- package/dist/read-command.js +19 -0
- package/dist/rolldown-runtime.js +1 -2
- package/dist/sheet-command.js +58 -0
- package/dist/webauthn-verify.js +3 -5
- package/package.json +13 -11
- package/dist/method/agents/noah/references/conduct.md +0 -102
- package/dist/method/skills/api-e2e-tests/references/frameworks.md +0 -58
- package/dist/method/skills/api-e2e-tests/references/generate.md +0 -67
- package/dist/method/skills/audit-pillars/references/accessibility.md +0 -13
- package/dist/method/skills/audit-pillars/references/architecture.md +0 -13
- package/dist/method/skills/audit-pillars/references/dependencies.md +0 -13
- package/dist/method/skills/audit-pillars/references/format.md +0 -20
- package/dist/method/skills/audit-pillars/references/interface.md +0 -13
- package/dist/method/skills/audit-pillars/references/method.md +0 -33
- package/dist/method/skills/audit-pillars/references/performance.md +0 -17
- package/dist/method/skills/audit-pillars/references/quality.md +0 -11
- package/dist/method/skills/audit-pillars/references/security.md +0 -13
- package/dist/method/skills/audit-pillars/references/tests.md +0 -17
- package/dist/method/skills/critique-deliverable/references/assumption-audit.md +0 -11
- package/dist/method/skills/critique-deliverable/references/compare-existing.md +0 -13
- package/dist/method/skills/critique-deliverable/references/devils-advocate.md +0 -13
- package/dist/method/skills/critique-deliverable/references/divergence.md +0 -15
- package/dist/method/skills/critique-deliverable/references/domain-expert.md +0 -14
- package/dist/method/skills/critique-deliverable/references/extreme-user.md +0 -13
- package/dist/method/skills/critique-deliverable/references/failure-modes.md +0 -13
- package/dist/method/skills/critique-deliverable/references/first-principles.md +0 -12
- package/dist/method/skills/critique-deliverable/references/inversion.md +0 -13
- package/dist/method/skills/critique-deliverable/references/pre-mortem.md +0 -12
- package/dist/method/skills/critique-deliverable/references/red-team.md +0 -12
- package/dist/method/skills/critique-deliverable/references/reframe.md +0 -12
- package/dist/method/skills/critique-deliverable/references/second-order.md +0 -12
- package/dist/method/skills/critique-deliverable/references/socratic.md +0 -15
- package/dist/method/skills/critique-deliverable/references/steelman.md +0 -13
- package/dist/method/skills/critique-deliverable/references/subtraction.md +0 -12
- package/dist/method/skills/develop-story/references/self-check.md +0 -46
- package/dist/method/skills/generate-knowledge-base/references/kb-checklist.md +0 -49
- package/dist/method/skills/generate-knowledge-base/references/repository-scan.md +0 -48
- package/dist/method/skills/ideation/references/choose.md +0 -21
- package/dist/method/skills/ideation/references/gestures.md +0 -15
- package/dist/method/skills/ideation/references/techniques-borrowed.md +0 -8
- package/dist/method/skills/ideation/references/techniques-deep.md +0 -12
- package/dist/method/skills/ideation/references/techniques-frames.md +0 -12
- package/dist/method/skills/ideation/references/techniques-futures.md +0 -8
- package/dist/method/skills/ideation/references/techniques-limits.md +0 -9
- package/dist/method/skills/ideation/references/techniques-people.md +0 -7
- package/dist/method/skills/ideation/references/techniques-sparks.md +0 -10
- package/dist/method/skills/ideation/references/techniques-together.md +0 -11
- package/dist/method/skills/order-merges/SKILL.md +0 -71
- package/dist/method/skills/pitch/references/deck-types.md +0 -17
- package/dist/method/skills/pitch/references/design-methods.md +0 -45
- package/dist/method/skills/pitch/references/design-thinking.md +0 -28
- package/dist/method/skills/pitch/references/story-frameworks.md +0 -39
- package/dist/method/skills/quick-lane/SKILL.md +0 -143
- package/dist/method/skills/review-tests/SKILL.md +0 -32
- package/dist/method/skills/review-tests/references/check.md +0 -25
- package/dist/method/skills/review-tests/references/grid.md +0 -27
- package/dist/method/skills/round-table/SKILL.md +0 -31
- package/dist/method/skills/round-table/evals/cases.yaml +0 -27
- package/dist/method/skills/round-table/references/cast.md +0 -14
- package/dist/method/skills/round-table/references/gestures.md +0 -24
- package/dist/method/skills/round-table/references/guests.md +0 -17
- package/dist/method/skills/round-table/references/independence.md +0 -21
- package/dist/method/skills/round-table/references/rooms.md +0 -29
- package/dist/method/skills/round-table/references/three-views.md +0 -17
- package/dist/method/skills/round-table/references/turns.md +0 -19
- package/dist/method/skills/strategy/references/innovate-frameworks.md +0 -48
- package/dist/method/skills/strategy/references/solve-methods.md +0 -45
- package/dist/method/skills/test-idea/references/bets.md +0 -14
- package/dist/method/skills/test-idea/references/concept.md +0 -24
- package/dist/method/skills/test-idea/references/verdict.md +0 -26
- package/dist/method/skills/workshop/references/analyze.md +0 -36
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Base CI for Go (go test, go vet, govulncheck): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the merge request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
image: golang:1.23
|
|
7
|
+
|
|
8
|
+
stages:
|
|
9
|
+
- check
|
|
10
|
+
|
|
11
|
+
default:
|
|
12
|
+
timeout: 30 minutes
|
|
13
|
+
|
|
14
|
+
lint:
|
|
15
|
+
stage: check
|
|
16
|
+
script:
|
|
17
|
+
- set -o pipefail
|
|
18
|
+
- mkdir -p reports
|
|
19
|
+
- 'go vet ./... 2>&1 | tee -a reports/lint.txt'
|
|
20
|
+
- 'gofmt -l . | tee -a reports/lint.txt'
|
|
21
|
+
- 'test -z "$(gofmt -l .)"'
|
|
22
|
+
artifacts:
|
|
23
|
+
when: on_failure
|
|
24
|
+
expire_in: 2 weeks
|
|
25
|
+
paths:
|
|
26
|
+
- reports/
|
|
27
|
+
|
|
28
|
+
test:
|
|
29
|
+
stage: check
|
|
30
|
+
script:
|
|
31
|
+
- set -o pipefail
|
|
32
|
+
- mkdir -p reports
|
|
33
|
+
- 'go test ./... 2>&1 | tee -a reports/test.txt'
|
|
34
|
+
artifacts:
|
|
35
|
+
when: on_failure
|
|
36
|
+
expire_in: 2 weeks
|
|
37
|
+
paths:
|
|
38
|
+
- reports/
|
|
39
|
+
|
|
40
|
+
build:
|
|
41
|
+
stage: check
|
|
42
|
+
script:
|
|
43
|
+
- set -o pipefail
|
|
44
|
+
- mkdir -p reports
|
|
45
|
+
- 'go build ./... 2>&1 | tee -a reports/build.txt'
|
|
46
|
+
artifacts:
|
|
47
|
+
when: on_failure
|
|
48
|
+
expire_in: 2 weeks
|
|
49
|
+
paths:
|
|
50
|
+
- reports/
|
|
51
|
+
|
|
52
|
+
audit:
|
|
53
|
+
stage: check
|
|
54
|
+
script:
|
|
55
|
+
- set -o pipefail
|
|
56
|
+
- mkdir -p reports
|
|
57
|
+
- 'go install golang.org/x/vuln/cmd/govulncheck@v1.1.4 2>&1 | tee -a reports/audit.txt'
|
|
58
|
+
- '$(go env GOPATH)/bin/govulncheck ./... 2>&1 | tee -a reports/audit.txt'
|
|
59
|
+
artifacts:
|
|
60
|
+
when: on_failure
|
|
61
|
+
expire_in: 2 weeks
|
|
62
|
+
paths:
|
|
63
|
+
- reports/
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
# Base CI for JVM with Gradle (test, check, dependency-check): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the pull request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
# Audit: add the plugin `org.owasp.dependencycheck` to the build; until then this job fails on purpose.
|
|
7
|
+
# Lint: runs the static checks the build declares (checkstyle, spotless...).
|
|
8
|
+
# Audit: without an NVD API key (nvd { apiKey } in the build, from a secret of the forge) the first vulnerability database download is very slow; the audit job allows 30 minutes.
|
|
9
|
+
name: CI
|
|
10
|
+
|
|
11
|
+
on:
|
|
12
|
+
pull_request:
|
|
13
|
+
push:
|
|
14
|
+
branches: [main]
|
|
15
|
+
|
|
16
|
+
permissions:
|
|
17
|
+
contents: read
|
|
18
|
+
|
|
19
|
+
concurrency:
|
|
20
|
+
group: ci-${{ github.ref }}
|
|
21
|
+
cancel-in-progress: true
|
|
22
|
+
|
|
23
|
+
defaults:
|
|
24
|
+
run:
|
|
25
|
+
shell: bash
|
|
26
|
+
|
|
27
|
+
jobs:
|
|
28
|
+
lint:
|
|
29
|
+
name: lint
|
|
30
|
+
runs-on: ubuntu-latest
|
|
31
|
+
timeout-minutes: 15
|
|
32
|
+
steps:
|
|
33
|
+
- uses: actions/checkout@v4
|
|
34
|
+
- uses: actions/setup-java@v4
|
|
35
|
+
with:
|
|
36
|
+
distribution: temurin
|
|
37
|
+
java-version: "21"
|
|
38
|
+
cache: gradle
|
|
39
|
+
- name: lint
|
|
40
|
+
run: |
|
|
41
|
+
mkdir -p reports
|
|
42
|
+
./gradlew --no-daemon check -x test 2>&1 | tee -a reports/lint.txt
|
|
43
|
+
- name: Keep the evidence
|
|
44
|
+
if: failure()
|
|
45
|
+
uses: actions/upload-artifact@v4
|
|
46
|
+
with:
|
|
47
|
+
name: lint-evidence
|
|
48
|
+
path: |
|
|
49
|
+
reports/
|
|
50
|
+
build/reports/
|
|
51
|
+
build/test-results/
|
|
52
|
+
if-no-files-found: ignore
|
|
53
|
+
retention-days: 14
|
|
54
|
+
|
|
55
|
+
test:
|
|
56
|
+
name: test
|
|
57
|
+
runs-on: ubuntu-latest
|
|
58
|
+
timeout-minutes: 30
|
|
59
|
+
steps:
|
|
60
|
+
- uses: actions/checkout@v4
|
|
61
|
+
- uses: actions/setup-java@v4
|
|
62
|
+
with:
|
|
63
|
+
distribution: temurin
|
|
64
|
+
java-version: "21"
|
|
65
|
+
cache: gradle
|
|
66
|
+
- name: test
|
|
67
|
+
run: |
|
|
68
|
+
mkdir -p reports
|
|
69
|
+
./gradlew --no-daemon test 2>&1 | tee -a reports/test.txt
|
|
70
|
+
- name: Keep the evidence
|
|
71
|
+
if: failure()
|
|
72
|
+
uses: actions/upload-artifact@v4
|
|
73
|
+
with:
|
|
74
|
+
name: test-evidence
|
|
75
|
+
path: |
|
|
76
|
+
reports/
|
|
77
|
+
build/reports/
|
|
78
|
+
build/test-results/
|
|
79
|
+
if-no-files-found: ignore
|
|
80
|
+
retention-days: 14
|
|
81
|
+
|
|
82
|
+
build:
|
|
83
|
+
name: build
|
|
84
|
+
runs-on: ubuntu-latest
|
|
85
|
+
timeout-minutes: 15
|
|
86
|
+
steps:
|
|
87
|
+
- uses: actions/checkout@v4
|
|
88
|
+
- uses: actions/setup-java@v4
|
|
89
|
+
with:
|
|
90
|
+
distribution: temurin
|
|
91
|
+
java-version: "21"
|
|
92
|
+
cache: gradle
|
|
93
|
+
- name: build
|
|
94
|
+
run: |
|
|
95
|
+
mkdir -p reports
|
|
96
|
+
./gradlew --no-daemon assemble 2>&1 | tee -a reports/build.txt
|
|
97
|
+
- name: Keep the evidence
|
|
98
|
+
if: failure()
|
|
99
|
+
uses: actions/upload-artifact@v4
|
|
100
|
+
with:
|
|
101
|
+
name: build-evidence
|
|
102
|
+
path: |
|
|
103
|
+
reports/
|
|
104
|
+
build/reports/
|
|
105
|
+
build/test-results/
|
|
106
|
+
if-no-files-found: ignore
|
|
107
|
+
retention-days: 14
|
|
108
|
+
|
|
109
|
+
audit:
|
|
110
|
+
name: audit
|
|
111
|
+
runs-on: ubuntu-latest
|
|
112
|
+
timeout-minutes: 30
|
|
113
|
+
steps:
|
|
114
|
+
- uses: actions/checkout@v4
|
|
115
|
+
- uses: actions/setup-java@v4
|
|
116
|
+
with:
|
|
117
|
+
distribution: temurin
|
|
118
|
+
java-version: "21"
|
|
119
|
+
cache: gradle
|
|
120
|
+
- name: audit
|
|
121
|
+
run: |
|
|
122
|
+
mkdir -p reports
|
|
123
|
+
./gradlew --no-daemon dependencyCheckAnalyze 2>&1 | tee -a reports/audit.txt
|
|
124
|
+
- name: Keep the evidence
|
|
125
|
+
if: failure()
|
|
126
|
+
uses: actions/upload-artifact@v4
|
|
127
|
+
with:
|
|
128
|
+
name: audit-evidence
|
|
129
|
+
path: |
|
|
130
|
+
reports/
|
|
131
|
+
build/reports/
|
|
132
|
+
build/test-results/
|
|
133
|
+
if-no-files-found: ignore
|
|
134
|
+
retention-days: 14
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
# Base CI for JVM with Gradle (test, check, dependency-check): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the merge request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
# Audit: add the plugin `org.owasp.dependencycheck` to the build; until then this job fails on purpose.
|
|
7
|
+
# Lint: runs the static checks the build declares (checkstyle, spotless...).
|
|
8
|
+
# Audit: without an NVD API key (nvd { apiKey } in the build, from a secret of the forge) the first vulnerability database download is very slow; the audit job allows 30 minutes.
|
|
9
|
+
image: gradle:8-jdk21
|
|
10
|
+
|
|
11
|
+
stages:
|
|
12
|
+
- check
|
|
13
|
+
|
|
14
|
+
default:
|
|
15
|
+
timeout: 30 minutes
|
|
16
|
+
|
|
17
|
+
lint:
|
|
18
|
+
stage: check
|
|
19
|
+
script:
|
|
20
|
+
- set -o pipefail
|
|
21
|
+
- mkdir -p reports
|
|
22
|
+
- './gradlew --no-daemon check -x test 2>&1 | tee -a reports/lint.txt'
|
|
23
|
+
artifacts:
|
|
24
|
+
when: on_failure
|
|
25
|
+
expire_in: 2 weeks
|
|
26
|
+
paths:
|
|
27
|
+
- reports/
|
|
28
|
+
- build/reports/
|
|
29
|
+
- build/test-results/
|
|
30
|
+
|
|
31
|
+
test:
|
|
32
|
+
stage: check
|
|
33
|
+
script:
|
|
34
|
+
- set -o pipefail
|
|
35
|
+
- mkdir -p reports
|
|
36
|
+
- './gradlew --no-daemon test 2>&1 | tee -a reports/test.txt'
|
|
37
|
+
artifacts:
|
|
38
|
+
when: on_failure
|
|
39
|
+
expire_in: 2 weeks
|
|
40
|
+
paths:
|
|
41
|
+
- reports/
|
|
42
|
+
- build/reports/
|
|
43
|
+
- build/test-results/
|
|
44
|
+
|
|
45
|
+
build:
|
|
46
|
+
stage: check
|
|
47
|
+
script:
|
|
48
|
+
- set -o pipefail
|
|
49
|
+
- mkdir -p reports
|
|
50
|
+
- './gradlew --no-daemon assemble 2>&1 | tee -a reports/build.txt'
|
|
51
|
+
artifacts:
|
|
52
|
+
when: on_failure
|
|
53
|
+
expire_in: 2 weeks
|
|
54
|
+
paths:
|
|
55
|
+
- reports/
|
|
56
|
+
- build/reports/
|
|
57
|
+
- build/test-results/
|
|
58
|
+
|
|
59
|
+
audit:
|
|
60
|
+
stage: check
|
|
61
|
+
script:
|
|
62
|
+
- set -o pipefail
|
|
63
|
+
- mkdir -p reports
|
|
64
|
+
- './gradlew --no-daemon dependencyCheckAnalyze 2>&1 | tee -a reports/audit.txt'
|
|
65
|
+
artifacts:
|
|
66
|
+
when: on_failure
|
|
67
|
+
expire_in: 2 weeks
|
|
68
|
+
paths:
|
|
69
|
+
- reports/
|
|
70
|
+
- build/reports/
|
|
71
|
+
- build/test-results/
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# Base CI for JVM with Maven (surefire, checkstyle, dependency-check): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the pull request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
# Lint: starts on the Google checkstyle rules; point it at your own configuration if you have one.
|
|
7
|
+
# Audit: without an NVD API key (a secret of the forge, passed as -DnvdApiKey=...) the first vulnerability database download is very slow; the audit job allows 30 minutes.
|
|
8
|
+
name: CI
|
|
9
|
+
|
|
10
|
+
on:
|
|
11
|
+
pull_request:
|
|
12
|
+
push:
|
|
13
|
+
branches: [main]
|
|
14
|
+
|
|
15
|
+
permissions:
|
|
16
|
+
contents: read
|
|
17
|
+
|
|
18
|
+
concurrency:
|
|
19
|
+
group: ci-${{ github.ref }}
|
|
20
|
+
cancel-in-progress: true
|
|
21
|
+
|
|
22
|
+
defaults:
|
|
23
|
+
run:
|
|
24
|
+
shell: bash
|
|
25
|
+
|
|
26
|
+
jobs:
|
|
27
|
+
lint:
|
|
28
|
+
name: lint
|
|
29
|
+
runs-on: ubuntu-latest
|
|
30
|
+
timeout-minutes: 15
|
|
31
|
+
steps:
|
|
32
|
+
- uses: actions/checkout@v4
|
|
33
|
+
- uses: actions/setup-java@v4
|
|
34
|
+
with:
|
|
35
|
+
distribution: temurin
|
|
36
|
+
java-version: "21"
|
|
37
|
+
cache: maven
|
|
38
|
+
- name: lint
|
|
39
|
+
run: |
|
|
40
|
+
mkdir -p reports
|
|
41
|
+
mvn -B checkstyle:check -Dcheckstyle.config.location=google_checks.xml -Dcheckstyle.violationSeverity=warning 2>&1 | tee -a reports/lint.txt
|
|
42
|
+
- name: Keep the evidence
|
|
43
|
+
if: failure()
|
|
44
|
+
uses: actions/upload-artifact@v4
|
|
45
|
+
with:
|
|
46
|
+
name: lint-evidence
|
|
47
|
+
path: |
|
|
48
|
+
reports/
|
|
49
|
+
target/surefire-reports/
|
|
50
|
+
target/dependency-check-report.html
|
|
51
|
+
if-no-files-found: ignore
|
|
52
|
+
retention-days: 14
|
|
53
|
+
|
|
54
|
+
test:
|
|
55
|
+
name: test
|
|
56
|
+
runs-on: ubuntu-latest
|
|
57
|
+
timeout-minutes: 30
|
|
58
|
+
steps:
|
|
59
|
+
- uses: actions/checkout@v4
|
|
60
|
+
- uses: actions/setup-java@v4
|
|
61
|
+
with:
|
|
62
|
+
distribution: temurin
|
|
63
|
+
java-version: "21"
|
|
64
|
+
cache: maven
|
|
65
|
+
- name: test
|
|
66
|
+
run: |
|
|
67
|
+
mkdir -p reports
|
|
68
|
+
mvn -B test 2>&1 | tee -a reports/test.txt
|
|
69
|
+
- name: Keep the evidence
|
|
70
|
+
if: failure()
|
|
71
|
+
uses: actions/upload-artifact@v4
|
|
72
|
+
with:
|
|
73
|
+
name: test-evidence
|
|
74
|
+
path: |
|
|
75
|
+
reports/
|
|
76
|
+
target/surefire-reports/
|
|
77
|
+
target/dependency-check-report.html
|
|
78
|
+
if-no-files-found: ignore
|
|
79
|
+
retention-days: 14
|
|
80
|
+
|
|
81
|
+
build:
|
|
82
|
+
name: build
|
|
83
|
+
runs-on: ubuntu-latest
|
|
84
|
+
timeout-minutes: 15
|
|
85
|
+
steps:
|
|
86
|
+
- uses: actions/checkout@v4
|
|
87
|
+
- uses: actions/setup-java@v4
|
|
88
|
+
with:
|
|
89
|
+
distribution: temurin
|
|
90
|
+
java-version: "21"
|
|
91
|
+
cache: maven
|
|
92
|
+
- name: build
|
|
93
|
+
run: |
|
|
94
|
+
mkdir -p reports
|
|
95
|
+
mvn -B -DskipTests package 2>&1 | tee -a reports/build.txt
|
|
96
|
+
- name: Keep the evidence
|
|
97
|
+
if: failure()
|
|
98
|
+
uses: actions/upload-artifact@v4
|
|
99
|
+
with:
|
|
100
|
+
name: build-evidence
|
|
101
|
+
path: |
|
|
102
|
+
reports/
|
|
103
|
+
target/surefire-reports/
|
|
104
|
+
target/dependency-check-report.html
|
|
105
|
+
if-no-files-found: ignore
|
|
106
|
+
retention-days: 14
|
|
107
|
+
|
|
108
|
+
audit:
|
|
109
|
+
name: audit
|
|
110
|
+
runs-on: ubuntu-latest
|
|
111
|
+
timeout-minutes: 30
|
|
112
|
+
steps:
|
|
113
|
+
- uses: actions/checkout@v4
|
|
114
|
+
- uses: actions/setup-java@v4
|
|
115
|
+
with:
|
|
116
|
+
distribution: temurin
|
|
117
|
+
java-version: "21"
|
|
118
|
+
cache: maven
|
|
119
|
+
- name: audit
|
|
120
|
+
run: |
|
|
121
|
+
mkdir -p reports
|
|
122
|
+
mvn -B org.owasp:dependency-check-maven:12.1.0:check -DfailBuildOnCVSS=7 2>&1 | tee -a reports/audit.txt
|
|
123
|
+
- name: Keep the evidence
|
|
124
|
+
if: failure()
|
|
125
|
+
uses: actions/upload-artifact@v4
|
|
126
|
+
with:
|
|
127
|
+
name: audit-evidence
|
|
128
|
+
path: |
|
|
129
|
+
reports/
|
|
130
|
+
target/surefire-reports/
|
|
131
|
+
target/dependency-check-report.html
|
|
132
|
+
if-no-files-found: ignore
|
|
133
|
+
retention-days: 14
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# Base CI for JVM with Maven (surefire, checkstyle, dependency-check): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the merge request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
# Lint: starts on the Google checkstyle rules; point it at your own configuration if you have one.
|
|
7
|
+
# Audit: without an NVD API key (a secret of the forge, passed as -DnvdApiKey=...) the first vulnerability database download is very slow; the audit job allows 30 minutes.
|
|
8
|
+
image: maven:3-eclipse-temurin-21
|
|
9
|
+
|
|
10
|
+
stages:
|
|
11
|
+
- check
|
|
12
|
+
|
|
13
|
+
default:
|
|
14
|
+
timeout: 30 minutes
|
|
15
|
+
|
|
16
|
+
lint:
|
|
17
|
+
stage: check
|
|
18
|
+
script:
|
|
19
|
+
- set -o pipefail
|
|
20
|
+
- mkdir -p reports
|
|
21
|
+
- 'mvn -B checkstyle:check -Dcheckstyle.config.location=google_checks.xml -Dcheckstyle.violationSeverity=warning 2>&1 | tee -a reports/lint.txt'
|
|
22
|
+
artifacts:
|
|
23
|
+
when: on_failure
|
|
24
|
+
expire_in: 2 weeks
|
|
25
|
+
paths:
|
|
26
|
+
- reports/
|
|
27
|
+
- target/surefire-reports/
|
|
28
|
+
- target/dependency-check-report.html
|
|
29
|
+
|
|
30
|
+
test:
|
|
31
|
+
stage: check
|
|
32
|
+
script:
|
|
33
|
+
- set -o pipefail
|
|
34
|
+
- mkdir -p reports
|
|
35
|
+
- 'mvn -B test 2>&1 | tee -a reports/test.txt'
|
|
36
|
+
artifacts:
|
|
37
|
+
when: on_failure
|
|
38
|
+
expire_in: 2 weeks
|
|
39
|
+
paths:
|
|
40
|
+
- reports/
|
|
41
|
+
- target/surefire-reports/
|
|
42
|
+
- target/dependency-check-report.html
|
|
43
|
+
|
|
44
|
+
build:
|
|
45
|
+
stage: check
|
|
46
|
+
script:
|
|
47
|
+
- set -o pipefail
|
|
48
|
+
- mkdir -p reports
|
|
49
|
+
- 'mvn -B -DskipTests package 2>&1 | tee -a reports/build.txt'
|
|
50
|
+
artifacts:
|
|
51
|
+
when: on_failure
|
|
52
|
+
expire_in: 2 weeks
|
|
53
|
+
paths:
|
|
54
|
+
- reports/
|
|
55
|
+
- target/surefire-reports/
|
|
56
|
+
- target/dependency-check-report.html
|
|
57
|
+
|
|
58
|
+
audit:
|
|
59
|
+
stage: check
|
|
60
|
+
script:
|
|
61
|
+
- set -o pipefail
|
|
62
|
+
- mkdir -p reports
|
|
63
|
+
- 'mvn -B org.owasp:dependency-check-maven:12.1.0:check -DfailBuildOnCVSS=7 2>&1 | tee -a reports/audit.txt'
|
|
64
|
+
artifacts:
|
|
65
|
+
when: on_failure
|
|
66
|
+
expire_in: 2 weeks
|
|
67
|
+
paths:
|
|
68
|
+
- reports/
|
|
69
|
+
- target/surefire-reports/
|
|
70
|
+
- target/dependency-check-report.html
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# Base CI for Python (pytest, ruff, pip-audit): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the pull request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
name: CI
|
|
7
|
+
|
|
8
|
+
on:
|
|
9
|
+
pull_request:
|
|
10
|
+
push:
|
|
11
|
+
branches: [main]
|
|
12
|
+
|
|
13
|
+
permissions:
|
|
14
|
+
contents: read
|
|
15
|
+
|
|
16
|
+
concurrency:
|
|
17
|
+
group: ci-${{ github.ref }}
|
|
18
|
+
cancel-in-progress: true
|
|
19
|
+
|
|
20
|
+
defaults:
|
|
21
|
+
run:
|
|
22
|
+
shell: bash
|
|
23
|
+
|
|
24
|
+
jobs:
|
|
25
|
+
lint:
|
|
26
|
+
name: lint
|
|
27
|
+
runs-on: ubuntu-latest
|
|
28
|
+
timeout-minutes: 15
|
|
29
|
+
steps:
|
|
30
|
+
- uses: actions/checkout@v4
|
|
31
|
+
- uses: actions/setup-python@v5
|
|
32
|
+
with:
|
|
33
|
+
python-version: "3.12"
|
|
34
|
+
- name: lint
|
|
35
|
+
run: |
|
|
36
|
+
mkdir -p reports
|
|
37
|
+
pip install ruff 2>&1 | tee -a reports/lint.txt
|
|
38
|
+
ruff check . 2>&1 | tee -a reports/lint.txt
|
|
39
|
+
ruff format --check . 2>&1 | tee -a reports/lint.txt
|
|
40
|
+
- name: Keep the evidence
|
|
41
|
+
if: failure()
|
|
42
|
+
uses: actions/upload-artifact@v4
|
|
43
|
+
with:
|
|
44
|
+
name: lint-evidence
|
|
45
|
+
path: |
|
|
46
|
+
reports/
|
|
47
|
+
if-no-files-found: ignore
|
|
48
|
+
retention-days: 14
|
|
49
|
+
|
|
50
|
+
test:
|
|
51
|
+
name: test
|
|
52
|
+
runs-on: ubuntu-latest
|
|
53
|
+
timeout-minutes: 30
|
|
54
|
+
steps:
|
|
55
|
+
- uses: actions/checkout@v4
|
|
56
|
+
- uses: actions/setup-python@v5
|
|
57
|
+
with:
|
|
58
|
+
python-version: "3.12"
|
|
59
|
+
- name: test
|
|
60
|
+
run: |
|
|
61
|
+
mkdir -p reports
|
|
62
|
+
if [ -f requirements.txt ]; then pip install -r requirements.txt; else pip install -e .; fi
|
|
63
|
+
pip install pytest 2>&1 | tee -a reports/test.txt
|
|
64
|
+
pytest --junitxml=reports/junit.xml 2>&1 | tee -a reports/test.txt
|
|
65
|
+
- name: Keep the evidence
|
|
66
|
+
if: failure()
|
|
67
|
+
uses: actions/upload-artifact@v4
|
|
68
|
+
with:
|
|
69
|
+
name: test-evidence
|
|
70
|
+
path: |
|
|
71
|
+
reports/
|
|
72
|
+
if-no-files-found: ignore
|
|
73
|
+
retention-days: 14
|
|
74
|
+
|
|
75
|
+
build:
|
|
76
|
+
name: build
|
|
77
|
+
runs-on: ubuntu-latest
|
|
78
|
+
timeout-minutes: 15
|
|
79
|
+
steps:
|
|
80
|
+
- uses: actions/checkout@v4
|
|
81
|
+
- uses: actions/setup-python@v5
|
|
82
|
+
with:
|
|
83
|
+
python-version: "3.12"
|
|
84
|
+
- name: build
|
|
85
|
+
run: |
|
|
86
|
+
mkdir -p reports
|
|
87
|
+
if [ -f requirements.txt ]; then pip install -r requirements.txt; else pip install -e .; fi
|
|
88
|
+
pip install build 2>&1 | tee -a reports/build.txt
|
|
89
|
+
python -m build 2>&1 | tee -a reports/build.txt
|
|
90
|
+
- name: Keep the evidence
|
|
91
|
+
if: failure()
|
|
92
|
+
uses: actions/upload-artifact@v4
|
|
93
|
+
with:
|
|
94
|
+
name: build-evidence
|
|
95
|
+
path: |
|
|
96
|
+
reports/
|
|
97
|
+
if-no-files-found: ignore
|
|
98
|
+
retention-days: 14
|
|
99
|
+
|
|
100
|
+
audit:
|
|
101
|
+
name: audit
|
|
102
|
+
runs-on: ubuntu-latest
|
|
103
|
+
timeout-minutes: 10
|
|
104
|
+
steps:
|
|
105
|
+
- uses: actions/checkout@v4
|
|
106
|
+
- uses: actions/setup-python@v5
|
|
107
|
+
with:
|
|
108
|
+
python-version: "3.12"
|
|
109
|
+
- name: audit
|
|
110
|
+
run: |
|
|
111
|
+
mkdir -p reports
|
|
112
|
+
if [ -f requirements.txt ]; then pip install -r requirements.txt; else pip install -e .; fi
|
|
113
|
+
pip install pip-audit 2>&1 | tee -a reports/audit.txt
|
|
114
|
+
pip-audit 2>&1 | tee -a reports/audit.txt
|
|
115
|
+
- name: Keep the evidence
|
|
116
|
+
if: failure()
|
|
117
|
+
uses: actions/upload-artifact@v4
|
|
118
|
+
with:
|
|
119
|
+
name: audit-evidence
|
|
120
|
+
path: |
|
|
121
|
+
reports/
|
|
122
|
+
if-no-files-found: ignore
|
|
123
|
+
retention-days: 14
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# Base CI for Python (pytest, ruff, pip-audit): a template of the method, advice only.
|
|
2
|
+
# Yours to edit or to leave: decline it and nothing else changes. It makes no call to the method;
|
|
3
|
+
# every tool below is the ecosystem's own and free.
|
|
4
|
+
# One job per check of the merge request (lint, test, build, audit). A failed job keeps its logs and
|
|
5
|
+
# reports in `reports/` as a CI artifact. Adjust versions and paths to your product.
|
|
6
|
+
image: python:3.12
|
|
7
|
+
|
|
8
|
+
stages:
|
|
9
|
+
- check
|
|
10
|
+
|
|
11
|
+
default:
|
|
12
|
+
timeout: 30 minutes
|
|
13
|
+
|
|
14
|
+
lint:
|
|
15
|
+
stage: check
|
|
16
|
+
script:
|
|
17
|
+
- set -o pipefail
|
|
18
|
+
- mkdir -p reports
|
|
19
|
+
- 'pip install ruff 2>&1 | tee -a reports/lint.txt'
|
|
20
|
+
- 'ruff check . 2>&1 | tee -a reports/lint.txt'
|
|
21
|
+
- 'ruff format --check . 2>&1 | tee -a reports/lint.txt'
|
|
22
|
+
artifacts:
|
|
23
|
+
when: on_failure
|
|
24
|
+
expire_in: 2 weeks
|
|
25
|
+
paths:
|
|
26
|
+
- reports/
|
|
27
|
+
|
|
28
|
+
test:
|
|
29
|
+
stage: check
|
|
30
|
+
script:
|
|
31
|
+
- set -o pipefail
|
|
32
|
+
- mkdir -p reports
|
|
33
|
+
- 'if [ -f requirements.txt ]; then pip install -r requirements.txt; else pip install -e .; fi'
|
|
34
|
+
- 'pip install pytest 2>&1 | tee -a reports/test.txt'
|
|
35
|
+
- 'pytest --junitxml=reports/junit.xml 2>&1 | tee -a reports/test.txt'
|
|
36
|
+
artifacts:
|
|
37
|
+
when: on_failure
|
|
38
|
+
expire_in: 2 weeks
|
|
39
|
+
paths:
|
|
40
|
+
- reports/
|
|
41
|
+
|
|
42
|
+
build:
|
|
43
|
+
stage: check
|
|
44
|
+
script:
|
|
45
|
+
- set -o pipefail
|
|
46
|
+
- mkdir -p reports
|
|
47
|
+
- 'if [ -f requirements.txt ]; then pip install -r requirements.txt; else pip install -e .; fi'
|
|
48
|
+
- 'pip install build 2>&1 | tee -a reports/build.txt'
|
|
49
|
+
- 'python -m build 2>&1 | tee -a reports/build.txt'
|
|
50
|
+
artifacts:
|
|
51
|
+
when: on_failure
|
|
52
|
+
expire_in: 2 weeks
|
|
53
|
+
paths:
|
|
54
|
+
- reports/
|
|
55
|
+
|
|
56
|
+
audit:
|
|
57
|
+
stage: check
|
|
58
|
+
script:
|
|
59
|
+
- set -o pipefail
|
|
60
|
+
- mkdir -p reports
|
|
61
|
+
- 'if [ -f requirements.txt ]; then pip install -r requirements.txt; else pip install -e .; fi'
|
|
62
|
+
- 'pip install pip-audit 2>&1 | tee -a reports/audit.txt'
|
|
63
|
+
- 'pip-audit 2>&1 | tee -a reports/audit.txt'
|
|
64
|
+
artifacts:
|
|
65
|
+
when: on_failure
|
|
66
|
+
expire_in: 2 weeks
|
|
67
|
+
paths:
|
|
68
|
+
- reports/
|