Hermex Output Review

← all cases

comply-human-warn-only

unchanged

Asserts — Warn and info findings are reported but do not fail the build — verdict wording plus exit 0.

Ran hermex comply --config configs/warn-only.config.ts in fixtures/ → exit 0, as asserted

Config fixtures/configs/warn-only.config.ts · Fixture fixtures (overview) · Case comply-human-warn-only (dossier)

Reproduce locally: pnpm run test:output -- --filter comply-human-warn-only

Config

fixtures/configs/warn-only.config.ts

import type { HermexConfigInput } from '../../src/config/types.ts';
import base from '../hermex.config.ts';

/**
 * The same rules as the primary config, none of them at `error`. Nothing
 * here can fail a build, so `comply` must exit 0 while still printing every
 * finding — and the verdict has to say "compliant" without pretending the
 * repo is clean. That wording is the whole point of the case.
 */
export default {
  ...base,
  rules: {
    detect_files: [
      {
        severity: 'warn',
        patterns: ['jest.config.*', '.babelrc'],
        message: 'Use vitest + Vite',
      },
    ],
    forbid_packages: [
      { severity: 'warn', patterns: ['moment'], message: 'Use date-fns or dayjs' },
    ],
    require_files: [
      { severity: 'warn', patterns: ['.nvmrc'] },
      { severity: 'info', patterns: ['.editorconfig'] },
    ],
    require_packages: [
      {
        severity: 'info',
        patterns: ['typescript'],
        message: 'TypeScript is required',
      },
    ],
    require_scripts: [
      {
        severity: 'warn',
        patterns: ['build', 'test'],
        message: 'Required npm scripts',
      },
    ],
    require_package_fields: [{ severity: 'warn', patterns: ['engines', 'license'] }],
    engine_version: { severity: 'info', range: '>=20', message: 'Minimum Node 20 required' },
  },
} satisfies HermexConfigInput;

Full output

stdout.txt
hermex v<version>
- Parsing lockfile...
✔ Found pnpm lockfile (supports: v5, v6, v9) - 5 packages
✔ Found 18 files
✔ Analysis complete! Analyzed 17/18 files

⚠ 1 file(s) failed to parse:
  broken/unparseable.tsx
      x Expression expected
   ,----
 1 | export const Broken = ( : : :;
   :                         ^
   `----


Caused by:
    Syntax Error


🔍 Rules

┌──────────────────┬──────────────────────────────────────────────────────┐
│ Rule             │ Description                                          │
├──────────────────┼──────────────────────────────────────────────────────┤
│ forbid_packages  │ 🟡 moment is forbidden — Use date-fns or dayjs       │
├──────────────────┼──────────────────────────────────────────────────────┤
│ require_packages │ 🔵 typescript not installed — TypeScript is required │
├──────────────────┼──────────────────────────────────────────────────────┤
│ require_files    │ 🟡 .nvmrc not found                                  │
├──────────────────┼──────────────────────────────────────────────────────┤
│ require_files    │ 🔵 .editorconfig not found                           │
└──────────────────┴──────────────────────────────────────────────────────┘

2 warnings

⚖️ Versus

  Design System Migration
  ──────────────────────────────────────────────────
  @design-system/foundation  ██████████████████████████████ 100.0% (33 usages)
  @new-system/arc            ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 0.0% (0 usages)


🟢 COMPLIANT
stderr.txt