Skip to content

Commit 46d14dc

Browse files
committed
feat: initial release — linked skills for AI agents
Made-with: Cursor
0 parents  commit 46d14dc

31 files changed

Lines changed: 4616 additions & 0 deletions

.cursorindexingignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
# Don't index SpecStory auto-save files, but allow explicit context inclusion via @ references
3+
.specstory/**

.github/workflows/ci.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
build-and-test:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
matrix:
14+
node-version: [18, 20]
15+
steps:
16+
- uses: actions/checkout@v4
17+
- uses: actions/setup-node@v4
18+
with:
19+
node-version: ${{ matrix.node-version }}
20+
cache: npm
21+
- run: npm ci
22+
- name: Configure git for tests
23+
run: |
24+
git config --global user.email "ci@skillet.dev"
25+
git config --global user.name "Skillet CI"
26+
git config --global init.defaultBranch main
27+
git config --global protocol.file.allow always
28+
- run: npm run build
29+
- run: npm run lint
30+
- run: npm test

.gitignore

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
node_modules/
2+
dist/
3+
*.tsbuildinfo
4+
.DS_Store
5+
6+
# AI development tooling (internal)
7+
.context/
8+
.specstory/
9+
.cursor/
10+
.claude/

.npmignore

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Source and config
2+
src/
3+
tests/
4+
tsconfig.json
5+
6+
# Documentation (README + LICENSE included via package.json files)
7+
ARCH.md
8+
CLAUDE.md
9+
SPEC.md
10+
TASKS.md
11+
12+
# AI development tooling
13+
.context/
14+
.claude/
15+
.cursor/
16+
17+
# Demo
18+
demo/
19+
20+
# Assets
21+
assets/
22+
23+
# GitHub
24+
.github/

ARCH.md

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# Architecture
2+
3+
## Overview
4+
5+
Skillet is a thin CLI wrapper over `git submodule` that makes it friendly to add, remove, and update AI agent skill repos in `.claude/skills/`.
6+
7+
## Core Design
8+
9+
```
10+
User CLI command → Commander parser → Command handler → git submodule operation
11+
```
12+
13+
No custom package manager, no registry, no config file. `.gitmodules` is the manifest.
14+
15+
## File Tree
16+
17+
```
18+
skillet/
19+
├── CLAUDE.md # AI working instructions
20+
├── SPEC.md # Product spec
21+
├── ARCH.md # This file
22+
├── TASKS.md # Task tracking
23+
├── README.md # Public docs
24+
├── package.json # npm config
25+
├── tsconfig.json # TypeScript config
26+
├── .context/ # AI memory bank
27+
│ ├── activeContext.md
28+
│ ├── progress.md
29+
│ ├── techContext.md
30+
│ └── systemPatterns.md
31+
├── .claude/ # Claude Code config
32+
│ ├── settings.json
33+
│ ├── hooks/
34+
│ ├── commands/
35+
│ └── skills/
36+
├── .cursor/ # Cursor IDE config
37+
│ └── rules/
38+
├── src/
39+
│ ├── cli.ts # Entry point, Commander setup
40+
│ ├── types.ts # Shared types
41+
│ ├── commands/
42+
│ │ ├── init.ts # Initialize submodules
43+
│ │ ├── add.ts # Add skill (submodule add)
44+
│ │ ├── remove.ts # Remove skill (deinit + rm + cleanup)
45+
│ │ ├── update.ts # Update skills (submodule update --remote)
46+
│ │ └── status.ts # Show skill status
47+
│ └── git/
48+
│ ├── submodule.ts # All git submodule operations
49+
│ └── resolve.ts # GitHub shorthand → URL resolution
50+
├── tests/
51+
│ └── git/
52+
│ ├── resolve.test.ts
53+
│ └── submodule.test.ts
54+
└── dist/ # Build output (gitignored)
55+
```
56+
57+
## Key Modules
58+
59+
### `src/git/resolve.ts`
60+
Resolves GitHub shorthand (`org/repo`) to full SSH URL (`git@github.com:org/repo.git`). Also accepts full SSH and HTTPS URLs passthrough.
61+
62+
### `src/git/submodule.ts`
63+
Wraps all `git submodule` commands via `child_process.exec`. Handles:
64+
- `add` with destination path and optional `--branch` for ref pinning
65+
- `deinit -f` + `git rm -f` + `.git/modules/` cleanup for removal
66+
- `update --remote --merge` for updates
67+
- `update --init` for initialization
68+
- `status` parsing into structured objects
69+
70+
### `src/commands/*`
71+
One file per CLI command. Each imports from `git/submodule.ts` and `git/resolve.ts`. Handles user output and error formatting.

CLAUDE.md

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# Skillet
2+
3+
Linked skills for AI agents. A friendly CLI wrapper over git submodules that adds skill repos directly into `.claude/skills/`.
4+
5+
## Quick start
6+
```bash
7+
npm install
8+
npm run build
9+
npm test
10+
```
11+
12+
## Build & test
13+
```bash
14+
npm run build # TypeScript → dist/
15+
npm test # vitest (18 tests)
16+
npm run dev # watch mode
17+
node dist/cli.js # run CLI locally
18+
```
19+
20+
## Architecture
21+
- Thin wrapper over `git submodule` commands -- no custom package manager
22+
- Skills are git submodules checked out into `.claude/skills/<name>`
23+
- GitHub shorthand (`org/repo`) resolves to `git@github.com:org/repo.git`
24+
- `commander` for CLI, `vitest` for tests
25+
- All git operations go through `src/git/submodule.ts`
26+
- URL resolution logic in `src/git/resolve.ts`
27+
28+
## Key files
29+
- `src/cli.ts` — CLI entry point, 6 commands
30+
- `src/git/submodule.ts` — all git submodule operations (add, remove, update, init, list)
31+
- `src/git/resolve.ts` — GitHub shorthand and URL resolution
32+
- `src/commands/` — one file per command
33+
- `tests/git/` — tests with real temporary git repos
34+
35+
## Non-negotiables
36+
- Strict TypeScript — no `any`
37+
- Never modify user's existing `.claude/skills/` content that wasn't added by skillet
38+
- Every new feature must have tests
39+
- Submodule operations must handle cleanup fully (deinit + git rm + .git/modules removal)
40+
- GitHub shorthand must always work alongside full git URLs
41+
42+
## How to work here
43+
- Small incremental commits with conventional messages (`feat:`, `fix:`, `refactor:`)
44+
- Run `npm test` before committing
45+
- The project is intentionally minimal — resist scope creep
46+
47+
## Forbidden patterns
48+
- No `any` types
49+
- No `console.log` in library code (only in command handlers for user output)
50+
- No custom package manager logic — git submodules are the mechanism
51+
- No registry, no cloud sync, no compile step (MVP scope)

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2026 Skillet Contributors
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)