Skip to content

arvindjuneja/MacDev

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

13 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš€ macOS Development Setup

Complete, automated setup for macOS development environments. Get up and running with essential dev tools, a beautiful terminal, tmux workflow, and a live Claude Code monitoring dashboard.

โœจ What This Does

This repository provides automated scripts to set up a complete development environment on macOS, including:

๐Ÿ› ๏ธ Development Tools

  • Homebrew - Package manager for macOS
  • Git - Version control
  • Python 3.11 with pyenv - Python version management
  • Node.js & npm - JavaScript runtime and package manager
  • Common utilities - tree, jq, wget, curl, htop

๐ŸŽจ Terminal Customization

  • Oh My Zsh - Powerful zsh framework
  • Powerlevel10k - Beautiful terminal theme
  • zsh plugins - Autosuggestions, syntax highlighting, and more
  • Modern CLI tools - eza, bat, fzf, fd, thefuck

๐Ÿ–ฅ๏ธ Terminal Multiplexer (tmux)

  • tmux with Catppuccin Mocha theme
  • TPM - Tmux Plugin Manager
  • tmux-resurrect & tmux-continuum - Session persistence
  • btop - Beautiful system monitor
  • dev-session - Pre-configured Claude Code workflow layout

๐Ÿ“Š Claude Code Monitor

  • Live TUI dashboard for tracking Claude Code CLI instances
  • Active instance tracking (PID, CPU%, uptime, project)
  • Today's message/session counts
  • Lifetime token usage by model (auto-scanned from session files)
  • Session & message history with active days count
  • Recent activity feed with timestamps
  • Works out of the box โ€” no config needed, reads directly from ~/.claude/
  • Catppuccin Mocha colors, flicker-free 5s refresh via rich

๐Ÿš€ Quick Start

One-Command Setup

./setup-macos.sh

This launches an interactive menu:

  1. Full Setup - Dev tools + Terminal + tmux
  2. Dev Environment Only - Essential development tools
  3. Terminal Only - Terminal beautification
  4. Multiplexer Only - tmux with Catppuccin theme + dev sessions
  5. Claude Monitor - Live dashboard for Claude Code instances
  6. Verify Setup - Check what's already installed
  7. Exit

๐Ÿ“‹ Prerequisites

  • macOS 11.0 or later
  • Terminal with zsh (default on modern macOS)
  • Internet connection
  • Admin privileges (for Homebrew installation)

๐Ÿ“ Repository Structure

MacDev/
โ”œโ”€โ”€ setup-macos.sh                # Main entry point (interactive menu)
โ”œโ”€โ”€ scripts/                      # Core setup scripts
โ”‚   โ”œโ”€โ”€ setup-dev-env.sh         # Development environment installer
โ”‚   โ”œโ”€โ”€ pimp-my-terminal.sh      # Terminal customization installer
โ”‚   โ”œโ”€โ”€ setup-tmux.sh            # tmux + theme + plugins installer
โ”‚   โ”œโ”€โ”€ setup-claude-monitor.sh  # Claude Code Monitor installer
โ”‚   โ”œโ”€โ”€ claude-monitor.py        # Live dashboard (rich TUI)
โ”‚   โ””โ”€โ”€ verify-setup.sh          # Verification script
โ”œโ”€โ”€ configs/                      # Configuration files
โ”‚   โ”œโ”€โ”€ tmux.conf                # tmux config (Catppuccin Mocha theme)
โ”‚   โ””โ”€โ”€ dev-session.sh           # Dev session layout launcher
โ”œโ”€โ”€ docs/                         # Documentation
โ”‚   โ”œโ”€โ”€ DEV_ENVIRONMENT_GUIDE.md
โ”‚   โ””โ”€โ”€ TERMINAL_SETUP_GUIDE.md
โ””โ”€โ”€ examples/                     # Project-specific examples
    โ”œโ”€โ”€ start_dev.sh
    โ”œโ”€โ”€ verify_setup_project.sh
    โ””โ”€โ”€ README.md

๐Ÿ“– Detailed Usage

Development Environment

./scripts/setup-dev-env.sh

Installs Homebrew, Git, Python 3.11 (via pyenv), Node.js & npm, and common utilities.

Terminal Customization

./scripts/pimp-my-terminal.sh

Installs Oh My Zsh, Powerlevel10k, zsh plugins, and modern CLI tools (eza, bat, fzf, fd, thefuck).

tmux Multiplexer

./scripts/setup-tmux.sh

Installs tmux with Catppuccin Mocha theme, TPM, session persistence plugins, btop, and the dev-session command for a Claude Code workflow layout.

Claude Code Monitor

./scripts/setup-claude-monitor.sh

Installs the live monitoring dashboard. Requires uv (auto-installed via Homebrew/installer).

Usage after install:

claude-monitor          # Live dashboard (5s refresh)
claude-monitor --once   # Single snapshot
claude-monitor -i 10    # Custom refresh interval
claude-monitor --compact # Compact mode for small tmux panes
cmon                    # Alias for claude-monitor

Dashboard shows:

โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ CLAUDE CODE MONITOR โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚  โ— 2 active instances                                                โ”‚
โ”‚  MacDev       PID 76988  CPU 11.9%   33m                             โ”‚
โ”‚  myproject    PID 23919  CPU 0.4%    2d 21h                          โ”‚
โ”‚                                                                      โ”‚
โ”‚  TODAY  Mar 14                                                       โ”‚
โ”‚  Messages โ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘  9                                         โ”‚
โ”‚  Sessions โ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘  2                                         โ”‚
โ”‚                                                                      โ”‚
โ”‚  TOKENS (lifetime)                                                   โ”‚
โ”‚  opus-4-6           97M tokens                                       โ”‚
โ”‚                                                                      โ”‚
โ”‚  RECENT                                                              โ”‚
โ”‚  18:49 MacDev     fix the login bug                                  โ”‚
โ”‚  18:47 myproject  add dark mode support                              โ”‚
โ”‚                                                                      โ”‚
โ”‚  LIFETIME  8 sessions ยท 43 msgs ยท 7 active days                      โ”‚
โ”‚  Since Feb 26, 2026                                                  โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ โ†ป 18:50:09 โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

Where does the data come from?

The monitor reads directly from Claude Code's local files โ€” no API keys or config needed:

Data Source
Active instances ps + lsof (running claude processes)
Today's messages/sessions ~/.claude/history.jsonl
Token usage per model ~/.claude/projects/*/*.jsonl (session files)
Lifetime stats ~/.claude/history.jsonl (all entries)
Recent activity ~/.claude/history.jsonl (last 5 entries)

If ~/.claude/stats-cache.json exists (some Claude Code versions generate it), the monitor uses that too for enriched stats.

Dev Session (tmux layout)

cd ~/projects/myapp
sc                    # that's it - launches everything

# also works as:
dev-session                              # same as sc, uses current dir
dev-session ~/projects/myapp             # give it a path
dev-session myapp ~/projects/myapp       # explicit name + path
dev-session --monitor=btop               # override system monitor

Creates a tmux layout optimized for Claude Code:

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                        โ”‚   Dev Server     โ”‚
โ”‚    Claude Code         โ”‚   (npm run dev)  โ”‚
โ”‚    (80% height)        โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚                        โ”‚   System Monitor โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค   (btop)         โ”‚
โ”‚    Claude Monitor      โ”‚                  โ”‚
โ”‚    (20% height)        โ”‚                  โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
        65% width              35% width
  • Bottom-left: Claude Monitor always runs here (live dashboard)
  • Bottom-right: System monitor (btop > htop > top, or --monitor=CMD)

Verify Setup

./scripts/verify-setup.sh

Checks all installed components including dev tools, terminal enhancements, tmux, and Claude Monitor.

๐ŸŽฏ What You Get

Terminal Features

ll                  # Beautiful file listing with icons
cat file.py         # Syntax highlighting with bat
Ctrl+R              # Fuzzy search command history
Ctrl+T              # Find files
gs                  # git status
fuck                # Fix your last command

tmux Keybindings (prefix = Ctrl+a)

Key Action
Ctrl+a | Split pane vertically
Ctrl+a - Split pane horizontally
Alt+arrows Navigate between panes
Shift+arrows Switch between windows
Ctrl+a z Zoom/unzoom current pane
Ctrl+a d Detach from session
Ctrl+a I Install plugins (capital I)

๐Ÿ”ง Customization

Configure Terminal Theme

p10k configure

Edit Shell Configuration

nano ~/.zshrc
source ~/.zshrc

๐Ÿ› Troubleshooting

Homebrew not found

eval "$(/opt/homebrew/bin/brew shellenv)"

Icons not showing in terminal

Install a Nerd Font (Powerlevel10k wizard will help).

Command not found after installation

source ~/.zshrc

uv cache permission error

If claude-monitor fails with a permission error on ~/.cache/uv:

sudo chown -R $(whoami) ~/.cache/uv

๐ŸŒŸ Features

  • โœ… Idempotent - Safe to run multiple times
  • โœ… Backs up your existing configuration
  • โœ… Modular - Use only what you need
  • โœ… Error handling - Stops on failures
  • โœ… Colorful output - Easy to follow progress
  • โœ… Zero-setup dependencies - uv run handles Python packages automatically

๐Ÿ™ Credits

This setup installs and configures these open-source projects:


Ready to pimp your development environment? Let's go! ๐Ÿš€

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors