$ show thoughtbot/laptop
The thoughtbot/laptop repository provides a shell script (`mac`) that sets up a macOS laptop for web and mobile development. The script automates installation and configuration of essential development tools including Homebrew, asdf, Git, Zsh, Heroku CLI, GitHub CLI, Ruby, Node.js, PostgreSQL, and Redis. It is designed to be idempotent, safe to run multiple times, and handles both Intel and Apple Silicon Macs, including installing Rosetta 2 when necessary. The script is well-structured with modular functions for common tasks like appending to zshrc, installing gems, managing asdf plugins, and updating the shell. These functions demonstrate non-obvious shell scripting skills and can be reused in other projects. The project is actively maintained with recent updates supporting the latest macOS versions and dependency updates.
The LLM identified 1 files worth highlighting for reuse:
The mac script contains several reusable shell functions (fancy_echo, append_to_zshrc, gem_install_or_update, update_shell, add_or_update_asdf_plugin, install_asdf_language) that demonstrate idempotent setup practices, safe file modification, and language version management. These functions are self-contained and can be extracted for use in other shell scripts with minimal modification.