ksk-incom/MacInventory
ksk-incom/MacInventory · 5 stars · 1 plugin
Marketplace MacInventory is a Claude Code Plugin that generates comprehensive Mac environment documentation and restoration guides. It solves the problem of documenting a Mac's computing environment (apps, configs, settings) for hardware failures or fresh starts.
Install
/plugin marketplace add ksk-incom/MacInventoryRun inside Claude Code, then install plugins from it. Check the repo's README before you run it.
Plugins 1
After adding the marketplace, install one with /plugin install <name>@macinventory-marketplace.
- 1macinventoryGenerate comprehensive Mac environment documentation and restoration guide
/plugin install macinventory@macinventory-marketplace
Files
MacInventory
Never lose your Mac setup again.
Quick Start • Features • Installation
Why MacInventory?
Ever had that sinking feeling when your Mac dies and you realize you don't remember half of what you had installed? Or spent hours manually recreating your dev environment on a new machine?
MacInventory is your insurance policy. One command captures everything - apps, packages, configs, extensions - and creates restoration scripts that actually work.
| Without MacInventory | With MacInventory |
|---|---|
| 😰 "What Homebrew packages did I have?" | ✅ brew bundle --file=Brewfile |
| 😰 "Where were my VS Code settings?" | ✅ All configs backed up automatically |
| 😰 "What was my shell configuration?" | ✅ .zshrc, .bashrc, aliases saved |
| 😰 "How did I set up that app?" | ✅ Professional Restoration Guide |
⚡ Quick Start
# 1. Start up your Claude Code claude # 2. Install the plugin (one-time) /plugin marketplace add ksk-incom/MacInventory /plugin install macinventory@MacInventory # 3. Run the inventory /macinventory:inventory
That's it. Follow the prompts, and in minutes you'll have a complete snapshot of your Mac.
✨ What It Does
MacInventory solves a common problem: documenting your Mac's computing environment for hardware failures, migrations, or fresh starts. It automatically:
- 📱 Scans installed applications (system and user)
- 🍺 Catalogs Homebrew packages, casks, and taps
- 🛒 Lists Mac App Store apps
- 🔄 Detects version managers (pyenv, nvm, rbenv, asdf)
- 📦 Inventories global packages (npm, pip, pipx, cargo, gem)
- ✏️ Captures editor extensions (VS Code, Cursor, Zed, Sublime)
- 🔐 Backs up configuration files with secret filtering
- 📋 Generates restoration bundles (Brewfile, package lists)
- 💾 Creates a comprehensive
state.yamlsnapshot - 📖 Optionally generates a professional Restoration Guide
📥 Installation
From Claude Code
# Add the marketplace (one-time) /plugin marketplace add ksk-incom/MacInventory # Install the plugin /plugin install macinventory@MacInventory
For Development
# Clone the repository git clone https://github.com/ksk-incom/MacInventory.git # Test locally without installing claude --plugin-dir ./macinventory
🚀 Usage
Run the inventory command in Claude Code:
/macinventory:inventory
You'll be guided through options:
- Security Settings - Whether to include files that may contain secrets
- Guide Generation - Whether to create a Restoration-Guide.md
- Cloud Backup - Optionally copy output to OneDrive, iCloud, Dropbox, or Google Drive
📂 Output Structure
After running, you'll have a timestamped directory with everything you need:
~/mac-inventory/2025-12-24-183045/
├── 📄 state.yaml # Complete system state snapshot
├── 📖 Restoration-Guide.md # Step-by-step restoration guide
├── 📦 bundles/ # Ready-to-use restoration files
│ ├── Brewfile # → brew bundle --file=Brewfile
│ ├── MASApps.txt # Mac App Store apps
│ ├── *Packages.txt # npm, pip, pipx, cargo, gem, go
│ └── *Extensions.txt # VS Code, Cursor, Zed extensions
└── ⚙️ configs/ # Backed-up configuration files
├── shell/ # .zshrc, .bashrc, aliases
├── git/ # .gitconfig, .gitignore_global
├── ssh/ # SSH config (not keys!)
└── apps/ # Per-app configs organized by tier
🎯 Features
Three-Tier Discovery
MacInventory uses a smart tiered approach to discover application configurations:
| Tier | Source | Trust Level | What It Does |
|---|---|---|---|
| 1 | Curated Database | ✅ High | Uses exact paths from app-hints.yaml |
| 2 | MacOS Conventions | ⚠️ Medium | Scans standard config locations |
| 3 | AI Research | ⚠️ Medium | Web search for unknown apps |
How the discovery flow works (click to expand)
┌─────────────────────────────────────────────────────────────────────────────┐
│ APPLICATION DISCOVERED │
│ (e.g., "iTerm") │
└─────────────────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────────────────┐
│ TIER 1: Hints Database ✓ TRUSTED │
│ ───────────────────────────────────────────────────────────────────────── │
│ Check app-hints.yaml for curated config paths │
│ │
│ Found? ──YES──► Use exact paths from database │
│ │ • No filtering applied (trusted source) │
│ │ • Backed up to: configs/apps/[app]/Tier 1 - App Hints/ │
│ │ │
│ │ │
└────┼────────────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────────────────┐
│ TIER 2: macOS Conventions ◐ FILTERED │
│ ───────────────────────────────────────────────────────────────────────── │
│ Scan standard macOS config locations: │
│ • ~/.config/[app-name]/ │
│ • ~/Library/Application Support/[app-name]/ │
│ • ~/Library/Preferences/[bundle-id].plist │
│ │
│ Found? ──YES──► Filter through config-patterns.yaml │
│ │ • Only safe extensions (.json, .yaml, .plist, etc.) │
│ │ • Exclude caches, logs, databases │
│ │ • Backed up to: configs/apps/[app]/Tier 2 - Conventions/ │
│ NO │
│ │ │
└────┼────────────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────────────────┐
│ TIER 3: LLM Research ◐ FILTERED │
│ ───────────────────────────────────────────────────────────────────────── │
│ Agent uses web search to discover config paths │
│ • Searches documentation, forums, GitHub │
│ • Validates discovered paths exist on system │
│ • Learns new apps for future runs │
│ │
│ Found? ──YES──► Filter through config-patterns.yaml │
│ │ • Same safety filtering as Tier 2 │
│ │ • Backed up to: configs/apps/[app]/Tier 3 - LLM Research/│
│ NO │
│ │ │
└────┼────────────────────────────────────────────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────────────────┐
│ UNDISCOVERED │
│ ───────────────────────────────────────────────────────────────────────── │
│ App added to undiscovered_report.yaml for manual review │
└─────────────────────────────────────────────────────────────────────────────┘
Example: How iTerm2 is discovered (click to expand)
Example: How "iTerm2" is Discovered
# Tier 1: Found in app-hints.yaml
iterm2:
bundle_id: com.googlecode.iterm2
install_method: homebrew_cask
configuration_files:
- ~/Library/Preferences/com.googlecode.iterm2.plist
- ~/Library/Application Support/iTerm2/DynamicProfiles/
notes: "Terminal emulator with extensive customization"
Because iTerm2 is in the hints database, MacInventory:
- Uses the exact paths specified (no guessing)
- Backs up without filtering (trusted source)
- Organizes files under
Tier 1 - App Hints Database/
For unknown apps, MacInventory:
- Scans standard macOS locations (Tier 2)
- Uses AI to research config paths (Tier 3)
- Filters results to only include safe file types
Filtering details (click to expand)
Tier 2 and 3 discoveries are filtered by config-patterns.yaml:
| ✅ Included | ❌ Excluded |
|---|---|
.json, .yaml, .toml |
.db, .sqlite, .realm |
.plist, .conf, .ini |
.log, .cache, Cache/ |
.sh, .zsh, .bash |
.dmg, .app, .pkg |
.xml, .cfg |
node_modules/, .git/ |
Maximum file size: 10 MB (larger files are likely not configs)
Security First
- Secret filtering enabled by default (API keys, tokens, passwords)
- SSH keys explicitly excluded
- Secure permissions on backed-up files (0600/0700)
- Home-relative paths only
Restoration Bundles
Generate files ready for system restoration:
# Restore Homebrew packages brew bundle --file=Brewfile # Restore npm globals xargs npm install -g < NPMGlobalPackages.txt # Restore pip packages pip install -r PipPackages.txt # Restore VS Code extensions while IFS= read -r ext; do code --install-extension "$ext"; done < VSCodeExtensions.txt
📋 Requirements
| Requirement | Status | Notes |
|---|---|---|
| macOS | Required | Any recent version |
| Python 3.12+ | Required | python3 --version |
| PyYAML | Required | pip3 install pyyaml |
| Homebrew | Recommended | Enables package scanning |
| mas-cli | Optional | Enhances App Store metadata |
🧩 Plugin Components
| Component | Description |
|---|---|
/macinventory:inventory |
Main command - runs the full inventory process |
app-discovery agent |
Researches unknown app config paths via web search |
config-validator agent |
Validates backed-up configs for quality |
guide-generator agent |
Creates professional restoration documentation |
prerequisites-checker agent |
Validates system prerequisites before inventory |
verification agent |
Final quality check on all output |
macos-discovery skill |
Knowledge base for researching macOS app settings |
🛡️ Privacy
- All data stays on your machine (unless you choose cloud backup)
- No telemetry or external connections (except optional LLM research)
- Secret filtering removes sensitive content from backups
- You control what gets included via command prompts
🔧 Troubleshooting
Missing Python/PyYAML
pip3 install pyyaml
Homebrew Not Found
The inventory continues without Homebrew data. Install it:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
mas-cli Not Found
Mac App Store apps still appear, but with limited metadata. Install mas:
brew install mas
Permission Errors
Some system files may be inaccessible. The plugin gracefully skips these and continues with accessible files.
🔍 Using the macOS Discovery Skill
The macos-discovery skill helps you research where macOS applications store their configuration files. Use it to add apps to the hints database.
Quick examples:
"Add Obsidian to the hints database""Where does TablePlus store its settings?""Research config paths for Raycast"
📖 Full skill documentation (click to expand)
When to Use This Skill
- Adding a specific app: You want to ensure a particular application's settings are backed up
- Processing undiscovered apps: After
/inventory, you see apps inundiscovered_report.yamlthat you want to track - Bulk discovery: You want to add all undiscovered apps from a previous inventory run
- Understanding config locations: You're curious where an app stores its settings
How to Invoke the Skill
The skill activates when you ask Claude about app configuration discovery. Use phrases like:
- "Add [AppName] to the hints database"
- "Where does [AppName] store its settings?"
- "Research app settings for [AppName]"
- "Find configuration paths for [AppName]"
Examples
Add a Single Application
Add Obsidian to the hints database
Claude will:
- Get the bundle ID (
osascript -e 'id of app "Obsidian"') - Check standard macOS config locations
- Search for documentation if needed
- Validate discovered paths exist on your system
- Create a properly formatted YAML entry
Research an Unknown App
Where does TablePlus store its configuration on macOS?
Claude will research the app and show you exactly which files contain settings vs cache/data.
Process Undiscovered Apps from Inventory
After running /inventory, if you have undiscovered apps:
Read the undiscovered_report.yaml from my last inventory and add all those apps
to the hints database. For each app, research the config locations and create
valid hints entries.
Optimized Prompt for Bulk Discovery
Use this prompt to systematically process all undiscovered apps from your latest inventory:
I just ran /inventory and have undiscovered apps. Please:
1. Read ~/mac-inventory/[latest-folder]/undiscovered_report.yaml
2. For each app listed:
- Get its bundle ID using osascript
- Determine the install method (cask, formula, mas, dmg)
- Check these locations for config files:
* ~/Library/Application Support/[AppName]/
* ~/Library/Preferences/[bundle_id].plist
* ~/.config/[appname]/
* ~/Library/Containers/[bundle_id]/ (if sandboxed)
- Search web for "[AppName] config location mac" if standard locations are empty
- Validate all discovered paths actually exist
3. Create valid app-hints.yaml entries for each app
4. Compile all entries into a single YAML block I can add to my hints database
5. Run the validate-hints.py script to verify the entries
Focus only on configuration files (settings, preferences, keybindings).
Exclude caches, logs, and databases. Use relative paths (no ~/ prefix).
Entry Format Quick Reference
app-name: # Lowercase, hyphenated
bundle_id: com.developer.AppName # From: osascript -e 'id of app "AppName"'
install_method: cask # cask | formula | mas | dmg | system
configuration_files: # Paths relative to $HOME (no ~/ prefix)
- Library/Application Support/AppName/settings.json
- Library/Preferences/com.developer.AppName.plist
xdg_configuration_files: # Paths relative to ~/.config (optional)
- appname/config.yaml
exclude_files: # Patterns to skip
- "*.log"
- "Cache/"
notes: "Optional notes about the app"
Key rules:
- Paths are RELATIVE (use
Library/...not~/Library/...) configuration_files= relative to$HOMExdg_configuration_files= relative to~/.config- Use
nullforbundle_idon CLI tools
Standard macOS Config Locations
The skill knows these common patterns:
| Location | Used By | Example |
|---|---|---|
~/Library/Application Support/ |
Modern GUI apps | Slack, VS Code, Discord |
~/Library/Preferences/*.plist |
Native macOS apps | iTerm2, Terminal |
~/.config/ |
CLI tools, cross-platform | neovim, starship, git |
~/Library/Containers/ |
Sandboxed (App Store) apps | Notes, 1Password |
~/.appname/ |
Traditional dotfiles | Docker, Warp |
Validation
After creating entries, validate them:
# Set your plugin path (adjust if using a different marketplace)
PLUGIN_PATH=~/.claude/plugins/macinventory@MacInventory
# Validate entire database
python3 $PLUGIN_PATH/skills/macos-discovery/scripts/validate-hints.py \
$PLUGIN_PATH/data/app-hints.yaml
# Validate and check paths exist
python3 $PLUGIN_PATH/skills/macos-discovery/scripts/validate-hints.py \
$PLUGIN_PATH/data/app-hints.yaml --check-paths --verbose
For developers: If working from the source repository, use
macinventory/as the path instead.
Made with ❤️ for the Mac community
{
"name": "macinventory-marketplace",
"owner": {
"name": "Kenneth Skou"
},
"metadata": {
"description": "Mac environment documentation and restoration plugin for Claude Code",
"version": "1.1.20"
},
"plugins": [
{
"name": "macinventory",
"source": "./macinventory",
"description": "Generate comprehensive Mac environment documentation and restoration guide",
"version": "1.1.20",
"author": {
"name": "Kenneth Skou"
},
"keywords": [
"macos",
"backup",
"inventory",
"restoration"
],
"license": "MIT"
}
]
}Facts
- Kind
- Marketplace
- Repo
- ksk-incom/MacInventory
- Group
- Uncategorized
- Stars
- 5
- Marketplace name
- macinventory-marketplace
- Owner
- Kenneth Skou
- Language
- Python
- Created
- 2025-12-23
- Last push
- 2026-09-08
- Plugins
- 1
Next on this shelf
- 1278open-horizon-labs/wmopen-horizon-labs/wm5
- 1279peabody124/reproducible_agent_environmentpeabody124/reproducible_agent_environment5
- 1280rlcurrall/aiderlcurrall/aide5
- 1281ruslan-korneev/claude-pluginsruslan-korneev/claude-plugins5
- 1282slamb2k/mad-skillsslamb2k/mad-skills5
- 1283ViktorHofer/dotnet-skillsViktorHofer/dotnet-skills5