Skip to content

unxed/f4 / .agents/skills/aif-ci

aif-ci

Flagged

Generate CI/CD pipeline (GitHub Actions / GitLab CI) with linting, static analysis, tests, security. Use when user says "ci", "setup ci", "github actions", "gitlab ci", "pipeline".

templates/gitlab/node.yml

View on GitHub
# GitLab CI — Node.js / TypeScript
# Template variables:
#   NODE_VERSION: e.g., 22
#   PACKAGE_MANAGER: npm | pnpm | yarn | bun
#   INSTALL_CMD: e.g., 'npm ci'
#   HAS_ESLINT: boolean
#   HAS_PRETTIER: boolean
#   HAS_BIOME: boolean
#   HAS_TYPESCRIPT: boolean
#   TEST_FRAMEWORK: jest | vitest
#   HAS_BUILD: boolean
#   WANT_COVERAGE: boolean

image: node:${NODE_VERSION}-slim

stages:
  - install
  - lint
  - test
  - build

workflow:
  rules:
    - if: $CI_PIPELINE_SOURCE == "merge_request_event"
    - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH

default:
  interruptible: true

variables:
  npm_config_cache: $CI_PROJECT_DIR/.npm

install:
  stage: install
  script:
    - ${INSTALL_CMD}
  cache:
    - key:
        files:
          - package-lock.json
      paths:
        - .npm/
      policy: pull-push
  artifacts:
    paths:
      - node_modules/
    expire_in: 1 hour

eslint:
  stage: lint
  needs: [install]
  script:
    - npx eslint . --format json --output-file eslint-report.json
  artifacts:
    reports:
      codequality: eslint-report.json
    when: always
  allow_failure: false

prettier:
  stage: lint
  needs: [install]
  script:
    - npx prettier --check .

# Or Biome (replaces BOTH ESLint and Prettier — use one or the other):
# biome:
#   stage: lint
#   needs: [install]
#   script:
#     - npx biome check .

typecheck:
  stage: lint
  needs: [install]
  script:
    - npx tsc --noEmit

tests:
  stage: test
  needs: [install]
  script:
    # Jest:
    - npx jest --coverage --ci --reporters=default --reporters=jest-junit
    # Or Vitest:
    # - npx vitest run --coverage --reporter=junit --outputFile=report.xml
  coverage: '/All files[^|]*\|[^|]*\s+([\d\.]+)/'
  artifacts:
    reports:
      junit: junit.xml
      coverage_report:
        coverage_format: cobertura
        path: coverage/cobertura-coverage.xml
    paths:
      - coverage/
    when: always

build:
  stage: build
  needs: [tests, eslint, typecheck]
  script:
    - npm run build
  artifacts:
    paths:
      - dist/
    expire_in: 7 days
rea-analysis-optimizationmorluto/reaOptimize REA providers and shared analysis workflows for agent context, latency, CPU, and memory while preserving correctness and Evidence. Use for analysis bottlenecks and cache or query design; CI/test-suite optimization belongs to rea-ci-tests-audit.Stars: 471kUpdated Claude CodeCodexVerifiedInstall
rea-ci-tests-auditmorluto/reaAudit REA CI and test suites for correctness, fixture drift, false passes, and measured performance; use for suite or workflow investigations and efficiency changes, rather than ordinary feature testing or a single test failure.Stars: 471kUpdated Claude CodeCodexVerifiedInstall
rea-tool-designmorluto/reaAudit, investigate, design, or change REA investigation tools, CLI/MCP contracts, provider capabilities, and Evidence semantics.Stars: 471kUpdated Claude CodeCodexVerifiedInstall
ponytail-auditDietrichGebert/ponytailQuality audit of the whole repo: bugs, security, real load, missing tests, speed, and what to delete. Most important first.Stars: 194kUpdated Claude CodeCodexVerifiedInstall