Building a happy MacOS workstation with all the things.
System Ruby, Homebrew, and Homebrew Bundle do the heavy lifting. But there is some lightweight Ruby-based shell scripting as well.
- MacOS Catalina or later
- Internet is connected
- Have a clean install of MacOS
- Run Terminal
- Run the following to bootstrap
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/infews/workstation_repave/main/bin/bootstrap)"...and watch the prompts
- Populate the file
~/.system_namewith the name you want for this computer - Run
bin/repaveto finish (See customization below)
The bin/bootstrap script will do the following:
- Install XCode's command line tools, which includes
git - Make the
~/workspacedirectory (for all your coding projects) - Clone this repo into
~/workspace - Prompt you to run the follow-on script
The bin/repave script runs the remaining tasks, relying heavily on Homebrew to finish the automatable tasks.
- The repo is cloned locally
- Anything that can be installed via Homebrew, will be installed via Homebrew Bundle with the Brewfile in
assets/Brewfile - Any dotfiles for various apps live in
dotfilesare managed and symlinked withrcm - Git is configured by generating a
.gitconfigthat includesassets/gitinclude- This is because Git won't load a symlinked dotfile
- Run other, personal tasks that live in
lib/repave
Yes, you will want to customize this repo.
- Fork this repo and customize
- Everyone is going to have different preferences and apps
- Consciously not extracting a grand unifying thing yet
- Assets
- Update
assets/Brewfilefor all your installable apps (Homebrew, casks, mac apps)assets/Brewfileto be used always
- Update
assets/gitincludefor git aliases & id's.gitconfigcannot be managed byrcm, so we build it at install time
- Update
- Dotfiles
- Dotfiles live in
dotfiles, without prepended dots per RCM convention- RCM is installed (via Homebrew) to manage the dotfiles
- See
dotfiles/rcrcfor which files are excluded
- Useful defaults based on how repave works live in
zshrc; Put anything you-specific inzshrc
- Dotfiles live in
- Add any other personal executable scripts to
bindotfiles/zshrcadds~/binto the$PATH
- Make your own tasks
- Add new Ruby classes in
lib/repaveto do work (see examples) - Edit/add any task classes to
bin/repave
- Add new Ruby classes in
- Why not just do this with shell scripts?
- Because I can never debug shell scripts. So Ruby FTW.
- Why not Ansible?
- Ruby FTW.
- Please make any tasks idempotnent. The
repavescript is meant to be run often. - Please do not add any external dependencies. This is meant to be run on a fresh MacOS very simply.