Executive Summary

Development environment setup is often treated as a one-time chore rather than a repeatable process. This article presents a configuration-as-code approach to macOS development environment setup—demonstrating how automation transforms a 3-4 hour manual process into a 15-minute automated task.


Introduction

Every developer knows the scenario: new Mac in hand, hours ahead, clicking through installer after installer.

This manual approach has hidden costs:

  • Time spent on repetitive setup tasks
  • Inconsistency across machines
  • Knowledge trapped in individual configurations
  • Friction in onboarding new team members

This article presents a practical approach to automating macOS development environment setup.

The Problem with Manual Setup

Typical Manual Process

  1. Install Homebrew packages (40+ apps)
  2. Configure VS Code with extensions
  3. Set up shell preferences
  4. Install GUI applications
  5. Configure everything by hand

Cost: 3-4 hours per machine, with significant inconsistency.

The Solution: Configuration as Code

Core Principles

Idempotency: Running the setup multiple times produces the same result.

Dry-Run Capability: Preview changes before execution.

Selective Installation: Install only what is needed.

Architecture Detection: Automatically adapts to hardware differences.

Implementation Approach

Homebrew as Foundation

Homebrew provides the foundation for CLI package management:

  • Binary bottles for fast installation
  • Automatic updates
  • Easy cleanup
  • Version management

Package Categories

CLI Tools (38 packages):

  • Productivity: eza, lsd, bat, fd, ripgrep, fzf
  • DevOps: kubectl, helm, terraform, docker
  • Monitoring: htop, k9s, tmux, starship
  • Languages: node, python, ruby, go, rust

GUI Applications (30 apps):

  • Browsers: Arc, Firefox, Chrome
  • Development: VS Code, Zed, Warp, TablePlus
  • Communication: Slack, Discord, Zoom
  • Productivity: Notion, Raycast, Rectangle

VS Code Extensions (84 extensions):

  • Themes and language servers
  • Git tools
  • Docker/Kubernetes integration
  • AI assistants

Implementation Pattern

# Core packages
brew "git"
brew "neovim"
brew "tmux"
brew "starship"

# Development tools
brew "node"
brew "python@3.13"
brew "go"

# CLI utilities
brew "eza"
brew "bat"
brew "fd"

# Applications
cask "visual-studio-code"
cask "arc"
cask "tableplus"

Key Features

Dry-Run Mode

Preview what would be installed without executing:

./setup.sh --dry-run

Selective Installation

Install only what is needed:

./setup.sh --cli-only    # CLI tools only
./setup.sh --cask-only   # GUI apps only

Architecture Detection

Automatically adapts to Apple Silicon vs Intel.

Idempotent Execution

Run multiple times safely—skips already-installed packages.

Results

Metric Before After
Setup Time 3-4 hours 15-20 minutes
Manual Clicks 200+ 0
Consistency Varies 100%

Best Practices

Configuration as Code

Your dotfiles and configs should be in version control:

  • Every setting tracked
  • Every preference reproducible
  • Changes auditable

Documentation

The best automation is well-documented:

  • What each component does
  • How to update
  • Troubleshooting steps

Conclusion

Automation is not about being lazy—it is about being efficient.

Key Takeaways:

  • Configuration as code enables reproducibility
  • Idempotent scripts enable confidence
  • Well-documented automation enables adoption

The investment in building automated setup pays dividends every time a new machine needs configuration.


About the Author

Designing DevOps and platform engineering capabilities that align technology with business goals—accelerating time-to-market and operational efficiency.

Connect: LinkedIn GitHub