Skip to content

Latest commit

 

History

History
133 lines (94 loc) · 2.99 KB

File metadata and controls

133 lines (94 loc) · 2.99 KB

Development

Guide for contributors working in the DNA monorepo.

Prerequisites

  • Node.js 20+
  • pnpm 9+

Setup

git clone https://github.com/superhumaan/DNA.git
cd DNA
pnpm install
pnpm build

Link the CLI globally (optional):

pnpm dna:link

Scripts

Command Description
pnpm build Build all packages
pnpm test Run Vitest (all packages)
pnpm typecheck TypeScript check all packages
pnpm lint ESLint
pnpm dna Run CLI from source
pnpm dna:link Build + global link
pnpm dna:setup Team setup script
pnpm publish:npm Publish all @superhumaan/* packages
pnpm gdpr:ingest Ingest GDPR .docx templates into bundled assets
pnpm gdpr:scrub Scrub vendor branding from GDPR templates

Monorepo layout

packages/
  dna-cli/        CLI entry (`dna` command)
  dna-core/       Scanner, wizard, generators, marketplace
  dna-config/     Typed config schemas, validators, constants
  dna-runtime/    Runtime observer + adapters
  dna-immune/     Issue classifier + DNA platform detection
  dna-feedback/   Upstream feedback (sanitize, queue, ingest)
  dna-github/     GitHub API
  dna-ai/         AI repair orchestrator
  dna-templates/  Install snippets
  dna-docs/       Doc utilities

apps/
  examples/       Express + Vite demos
  marketplace/    Standalone marketplace API (local dev)

# Public web surface: dna.humaan.app
# Landing highlights portfolio install — sync copy from docs/product/portfolio-install.md

Local environment variables

Variable Purpose
DNA_REFERENCE_ROOT Parent dir of reference repos for dna platform projects
DNA_GDPR_SOURCE_DOCS Source .docx folder for pnpm gdpr:ingest
DNA_MARKETPLACE_URL Override remote marketplace URL
DNA_FEEDBACK_URL Override upstream feedback API (dna feedback report, runtime auto-report)
DNA_FEEDBACK_TOKEN Maintainer token for dna feedback ingest (never commit)
NPM_TOKEN Required for pnpm publish:npm

Full list for end users: Integrations.


Package dependency order (publish)

Public on npm:

  • @superhumaan/dna-by-humaan — bundled CLI + /runtime export

Internal packages are private in the monorepo.

export NPM_TOKEN=<token>
pnpm publish:npm

CI

GitHub Actions runs on push/PR to main:

  • pnpm install
  • pnpm build
  • pnpm test
  • pnpm typecheck

Adding a knowledge pack

  1. Add pack definition under packages/dna-core/src/marketplace/.
  2. Register in bundled-catalog.ts if it belongs in the core bundle.
  3. Rebuild and test:
pnpm build
pnpm test

For retired pack IDs, add aliases in marketplace/aliases.ts.


Contributing

See CONTRIBUTING.md.

See also