ensure-repo-license

Ensure Kevin's open-source repos ship with an MIT LICENSE before publish or on audit. Use when creating a new public repo, open-sourcing a project, publishing to npm/GitHub, Kevin says "add license", "MIT license", "missing LICENSE", "license audit", or before marking a repo public. Runs audit + apply via scripts/ensure-mit-license.ts and agent-docs license doctor check.

Category
Engineering
Skill
049 of 261
Source
Kevin wiki

Kevin's personal public repos default to MIT with copyright Kevin B. Liu.

When to run

  1. New public repo — add LICENSE in the first commit (or before flipping isPrivate: false).
  2. Open-sourcing an existing repo — audit, add MIT, confirm GitHub shows MIT in repo sidebar.
  3. Weekly automationoss-license-audit automation (see automations/oss-license-audit.md).
  4. Agent-docs doctor — warns when LICENSE is missing on any enrolled repo.

Skip for private company repos (Dedalus org, etc.) unless Kevin explicitly open-sources them.

Commands

From kevin-wiki:

# Audit all public repos under Kevin-Liu-01
npx tsx scripts/ensure-mit-license.ts audit --owner Kevin-Liu-01

# Dry-run bulk apply
npx tsx scripts/ensure-mit-license.ts apply --owner Kevin-Liu-01 --dry-run

# Apply to all missing
npx tsx scripts/ensure-mit-license.ts apply --owner Kevin-Liu-01

# Single repo (GitHub API — no clone needed)
npx tsx scripts/ensure-mit-license.ts apply --repo Kevin-Liu-01/my-project

# Local clone
npx tsx scripts/ensure-mit-license.ts apply --local ~/Documents/GitHub/my-project

After adding locally, commit and push:

git add LICENSE && git commit -m "Add MIT license" && git push

New repo checklist

When Kevin (or an agent) creates a new public repo:

  1. Copy MIT text from scripts/lib/mit-license.ts → root LICENSE
  2. Add "license": "MIT" to package.json if present
  3. Optional README badge: [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
  4. On GitHub: Settings → General → set license to MIT (auto-detected once LICENSE is on default branch)

Enforcement layers

LayerMechanism
Doctoragent-docs doctor warns on missing/non-MIT LICENSE
Automationoss-license-audit weekly — audit + apply gaps
Tooling docwiki/meta/required-project-tooling.md § Layer 0
This skillAgent procedure for one-off fixes
  • scripts/ensure-mit-license.ts — audit/apply CLI
  • scripts/lib/mit-license.ts — canonical MIT template
  • automations/oss-license-audit.md — recurring audit
  • wiki/meta/required-project-tooling.md — stack checklist