Development (and more) environment setup for MacOS. Automatically syncs to make cloning your machine a breeze.
Built with:
- Fork
- Change "jamesjarvis" to your GitHub username in
install.sh
- Edit
dotfiles/.gitconfig
curl https://raw.githubusercontent.com/<your-username>/laptop/master/install.sh | bash
NOTE: No sudo
NOTE: If you don't like curl-ing into bash, you can install git and clone this repo, then run ./install.sh
.
There are 4 types of scripts, designated by the first digit:
Digit | Type |
---|---|
0 | install |
1 | system configuration |
2 | environment configuration |
3 | chores |
- Install and system configuration scripts are ran once by the main install script
- Environment configuration scripts are ran in the current context each time a shell is opened
- Chores are ran in a spawned process (screen) each time a shell is opened
For install and configuration scripts (system and environment) the second digit allows controlling the order of execution.
Keybase is used to securely sync secrets (gpg keys and private environment variables).
tl;dr it creates a /keybase
directory that is mounted via the network (configuration uses symlinks, so these never touch your disk). If you aren't familiar with Keybase, you should check it out further (no affiliation, it's just a fantastic product).
This setup will automatically import the following files:
/keybase/private/*/
├── .keys
│ └── *
└── vars.sh // secure environment variables (e.g. `export AWS_ACCESS_KEY_ID=...`)
The benefits of storing your keys (encrypted) in the cloud is not only syncing across machines or installs, but also revocability via Keybase (although you should still change your keys if you have reason to believe theyve been compromised).