Skip to content

Works on *nix, optimized for macOS. Managed using Stow

License

Notifications You must be signed in to change notification settings

sanswalden/dotfiles-1

 
 

Repository files navigation

My dotfiles.

Works on *nix, optimized for OS X.

Managed using Stow, so you can pick and choose which programs to install.


Philosophy

Initially I tried entirely automating the entire install process, but quickly found it wasn't worth the maintenance. Starting from scratch happens so rarely for me that each time I was fiddling with the bootstrap scripts to work around a random issue (often due to a new version of OSX).

Instead, it's simpler to install stuff by hand, and manage only the configuration files (dotfiles) in this repo.


Install steps on a clean OSX machine:

  1. Make hidden files/folder visible in Finder: defaults write -g AppleShowAllFiles -bool true

  2. git clone git@github.com:jeffwidman/dotfiles.git ~/.dotfiles

  • If cloning to a server without a Github-connected SSH key use 'https' instead: git clone https://github.com/jeffwidman/dotfiles.git ~/.dotfiles
  1. Install desired binaries using your favorite package manager:
  • If on OSX, use Homebrew:
    1. Install Homebrew.
    2. Install Homebrew Bundle: $ brew tap Homebrew/bundle
    3. $ brew bundle --file=~/.dotfiles/homebrew/.Brewfile After the .Brewfile is symlinked into ``~/.Brewfile, just use $ brew bundle --global`.
  • Make sure Stow gets installed, we'll use this later to symlink the dotfiles.
  • Ruby:
    1. Use rvm instead of Homebrew. Much easier to manage gemsets, ruby versions, etc.
  • Node:
    1. Use nvm instead of Homebrew for managing Node.
    2. Install/upgrade [manually using git] (https://github.com/creationix/nvm#manual-install) rather than nvm's install.sh script.
    3. Unfortunately, nvm drastically slows shell startup time due to nvm-sh/nvm#966, so after installing node (nvm install node), run nvm unalias default to disable the alias. Just remember to first run nvm use node whenever you want to run webpack, etc.
  1. Make ZSH the default shell:

  2. $ sudo vim /etc/shells

  3. Append the path to zsh - Homebrew sticks it in /usr/local/bin/zsh

  4. Save and exit

  5. $ chsh -s /usr/local/bin/zsh

  6. Install Prezto: git clone --recursive git@github.com:sorin-ionescu/prezto.git "${ZDOTDIR:-$HOME}/.zprezto"

  • The default Prezto instructions say to symlink the default config files. Don't do this; instead use Stow to symlink your own config files (instructions below).
  • To update Prezto: git pull && git submodule update --init --recursive
  1. Now use stow to symlink the various config files:
  1. Other apps I commonly install:
  1. ZSH completion scripts: Symlink any completion scripts into /usr/local/share/zsh/site-functions/. The filename must begin with an _ or zsh will not read it. Prezto caches the output of compinit, to rebuild the cache do: rm -rf ~/.zcomp* && compinit

Note: Many homebrew formula automatically handle installing the formula's completion scripts. For example, brew install the_silver_searcher(ag) will also install a completion script for ag in /usr/local/share/zsh/site-functions/.

Docker completion scripts - I opened sorin-ionescu/prezto#1459 to try to get this into prezto:

ln -s /Applications/Docker.app/Contents/Resources/etc/docker.zsh-completion /usr/local/share/zsh/site-functions/_docker
ln -s /Applications/Docker.app/Contents/Resources/etc/docker-machine.zsh-completion /usr/local/share/zsh/site-functions/_docker-machine
ln -s /Applications/Docker.app/Contents/Resources/etc/docker-compose.zsh-completion /usr/local/share/zsh/site-functions/_docker-compose

##List of config files

  • VSCode - Settings are stowable, but extensions are purposefully excluded. At this time, there's no way to favorite/bookmark recommendations on the Visual Studio Marketplace. When there is, I'll start creating a list of the ones I use.
  • bash
  • git
  • Homebrew Brewfile - stowable, brew bundle --global will use $HOME/.Brewfile
  • nvim - Neovim. No need to stow as it respects $XDG_CONFIG_HOME
  • python - not stowable, use pip install -r ~/.dotfiles/python/requirements.txt
  • ruby
  • tmux - #TODO
  • vim - for when Neovim isn't available
  • vimify - .inputrc and .editrc make vim commands work in many interactive shells, for example the mysql and postgres shells
  • zsh - includes prezto config files

##Misc Notes:

List of possible macOS customizations: https://mths.be/macos

For themes, check out the Base16 template system. It includes templates for theming many different apps.

Colorschemes that I like:

  • monokai
  • solarized
  • railscasts

Fonts that I like:

  • Ubuntu Monospace including powerline fix
  • Adobe Source Code (look for powerline fix)

##TODO:


Thanks


License

Copyright 2015 Jeff Widman Licensed under the MIT License

About

Works on *nix, optimized for macOS. Managed using Stow

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 52.0%
  • Vim Script 48.0%