Initialize user-level KERNEL foundations at ~/.claude/
Creates user-level Claude Code foundations at ~/.claude/ with universal principles and preferences.
/plugin marketplace add ariaxhan/kernel-plugin/plugin install kernel@kernel-marketplaceCreate the universal foundation layer at ~/.claude/. This is the always-present base layer that applies to ALL projects.
PRECEDENCE: Project > User > Plugin defaults
~/.claude/ <-- UNIVERSAL (this command)
├── CLAUDE.md Always loaded in Claude Code
├── rules/ User rules (always loaded)
└── changelog.md Track evolution
./CLAUDE.md <-- PROJECT-SPECIFIC (kernel-init)
└── kernel/ Project methodology
Search for the bank in order:
kernel/banks/CODING-PROMPT-BANK.md~/.claude/CODING-PROMPT-BANK.mdRead the entire bank. This is the substrate for building user config.
Extract sections tagged [USER-LEVEL]:
ls -la ~/.claude/ 2>/dev/null || echo "NOT_FOUND"
If ~/.claude/CLAUDE.md exists:
Ask user:
If NOT_FOUND: Proceed to create fresh installation.
Ask user if they want to customize preferences now or later:
If now, ask about:
Verbosity: How detailed should responses be?
Platform: Primary development environment?
Editor/IDE: Primary tool?
Store preferences for inclusion in generated CLAUDE.md.
If later: Use defaults, user can edit ~/.claude/CLAUDE.md directly.
If updating existing installation:
Create backup directory:
mkdir -p ~/.claude/backup
Backup current file with timestamp:
cp ~/.claude/CLAUDE.md ~/.claude/backup/CLAUDE-$(date +%Y%m%d-%H%M%S).md
Append to changelog.
mkdir -p ~/.claude/rules
mkdir -p ~/.claude/backup
Build ~/.claude/CLAUDE.md by extracting from CODING-PROMPT-BANK:
# Universal Development Principles
These principles apply to ALL projects, regardless of stack or domain.
---
[INSERT: CORE PHILOSOPHY section from bank]
---
[INSERT: GIT WORKFLOW section from bank]
---
[INSERT: DEFAULTS section from bank]
---
## Response Preferences
[INSERT: User preferences from Step 3, or placeholder template]
---
## KERNEL Integration
When KERNEL is initialized in a project (`/kernel:init`), project-level config takes precedence over these user defaults.
**Layer hierarchy:**
1. Project `.claude/CLAUDE.md` + `kernel/` (highest priority)
2. User `~/.claude/CLAUDE.md` + `~/.claude/rules/` (this file)
3. Plugin defaults (lowest priority)
Project-specific rules (tier, stack, domain, constraints) belong in project config.
Universal principles (philosophy, git workflow, defaults) live here.
---
Generated by KERNEL `/kernel:user-init`
Source: CODING-PROMPT-BANK v1.1
Last updated: {TIMESTAMP}
Replace {TIMESTAMP} with current UTC timestamp.
Write to ~/.claude/changelog.md:
# KERNEL User Configuration Changelog
---
## {DATE} {TIME} (UTC)
**Action:** [Initial installation | Update] via /kernel:user-init
**Source:** CODING-PROMPT-BANK v1.1
**Files:** ~/.claude/CLAUDE.md, ~/.claude/rules/, ~/.claude/changelog.md
**Preferences:** [Customized | Defaults]
Output summary:
KERNEL User Foundations Installed
Location: ~/.claude/
Created:
~/.claude/CLAUDE.md - Universal principles (always loaded)
~/.claude/rules/ - User rules directory
~/.claude/changelog.md - Change tracking
Content extracted from CODING-PROMPT-BANK:
- Core Philosophy (CORRECTNESS > SPEED, etc.)
- Git Workflow (worktree-based isolated development)
- Defaults (clarity, explicit, existing patterns)
- Quick Reference (checklists)
Git Workflow Summary:
Create worktrees for isolated work (never work directly on main):
git worktree add -b feat/my-feature ../project-feat-my-feature
open -a Terminal ../project-feat-my-feature
Next steps:
1. Customize ~/.claude/CLAUDE.md response preferences
2. Add user rules to ~/.claude/rules/ as patterns emerge
3. Run /kernel:init in projects to add project-specific config
Note: These foundations apply to ALL Claude Code sessions.
Project-level config (when present) takes precedence.
When extracting from CODING-PROMPT-BANK: