Skip to content

Instantly share code, notes, and snippets.

@maxackerman
Last active July 23, 2023 15:21
Show Gist options
  • Save maxackerman/930146246c6a023f4ac0e7c09cf05a68 to your computer and use it in GitHub Desktop.
Save maxackerman/930146246c6a023f4ac0e7c09cf05a68 to your computer and use it in GitHub Desktop.

Revisions

  1. maxackerman revised this gist Jan 11, 2023. 1 changed file with 0 additions and 12 deletions.
    12 changes: 0 additions & 12 deletions .zshrc
    Original file line number Diff line number Diff line change
    @@ -1,12 +0,0 @@
    export PATH=/usr/local/bin:$PATH
    export PATH="$PATH:$HOME/.composer/vendor/bin"

    if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi

    webmp4() {
    local maxwidth=1000
    local maxheight=1000
    for f; do
    ffmpeg -i "$f" -an -vcodec libx264 -vb 8000k -vf "scale=iw*min($maxwidth/iw\,$maxheight/ih):ih*min($maxwidth/iw\,$maxheight/ih)" -f mp4 "${f%.*}.mp4"
    done
    }
  2. maxackerman revised this gist Jan 11, 2023. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -236,8 +236,8 @@ echo "Setup process complete!"
    # xcode cli tools run: "xcode-select --install"
    # git config
    # setup Dropbox
    # Sublime: link settings in dropbox with symlink (https://packagecontrol.io/docs/syncing#dropbox-osx)
    # Alfred: link settings in dropbox
    # Sublime: link settings in dropbox with symlink
    # RightFont: link dropbox
    # arq
    # authy
  3. maxackerman revised this gist Dec 15, 2022. 1 changed file with 154 additions and 57 deletions.
    211 changes: 154 additions & 57 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -6,62 +6,134 @@
    # SSH keys
    # Fonts
    # Keychain passwords
    # files outside dropbox: downloads, documents, photos
    # files outside dropbox: downloads, documents, photos, photobooth
    # bash/zsh profile
    # transmit favs
    # photobooth pics

    # reference:
    # https://github.com/thoughtbot/laptop
    # https://github.com/tylucaskelley/setup
    # http://sourabhbajaj.com/mac-setup/

    echo "Starting configuration..."
    fancy_echo() {
    local fmt="$1"; shift

    if ! brew help &> /dev/null; then
    echo "installing homebrew..."
    /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
    # shellcheck disable=SC2059
    printf "\\n$fmt\\n" "$@"
    }

    append_to_zshrc() {
    local text="$1" zshrc
    local skip_new_line="${2:-0}"

    if [ -w "$HOME/.zshrc.local" ]; then
    zshrc="$HOME/.zshrc.local"
    else
    zshrc="$HOME/.zshrc"
    fi

    if ! grep -Fqs "$text" "$zshrc"; then
    if [ "$skip_new_line" -eq 1 ]; then
    printf "%s\\n" "$text" >> "$zshrc"
    else
    printf "\\n%s\\n" "$text" >> "$zshrc"
    fi
    fi
    }

    # shellcheck disable=SC2154
    trap 'ret=$?; test $ret -ne 0 && printf "failed\n\n" >&2; exit $ret' EXIT

    set -e

    if [ ! -d "$HOME/.bin/" ]; then
    mkdir "$HOME/.bin"
    fi

    if [ ! -f "$HOME/.zshrc" ]; then
    touch "$HOME/.zshrc"
    fi

    # shellcheck disable=SC2016
    append_to_zshrc 'export PATH="$HOME/.bin:$PATH"'


    # Determine Homebrew prefix
    arch="$(uname -m)"
    if [ "$arch" = "arm64" ]; then
    HOMEBREW_PREFIX="/opt/homebrew"
    else
    echo "homebrew already installed"
    HOMEBREW_PREFIX="/usr/local"
    fi

    update_shell() {
    local shell_path;
    shell_path="$(command -v zsh)"

    fancy_echo "Changing your shell to zsh ..."
    if ! grep "$shell_path" /etc/shells > /dev/null 2>&1 ; then
    fancy_echo "Adding '$shell_path' to /etc/shells"
    sudo sh -c "echo $shell_path >> /etc/shells"
    fi
    sudo chsh -s "$shell_path" "$USER"
    }

    case "$SHELL" in
    */zsh)
    if [ "$(command -v zsh)" != '/usr/local/bin/zsh' ] ; then
    update_shell
    fi
    ;;
    *)
    update_shell
    ;;
    esac

    if ! command -v brew >/dev/null; then
    fancy_echo "Installing Homebrew ..."
    /bin/bash -c \
    "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

    append_to_zshrc "eval \"\$($HOMEBREW_PREFIX/bin/brew shellenv)\""

    export PATH="$HOMEBREW_PREFIX/bin:$PATH"
    fi

    if brew list | grep -Fq brew-cask; then
    fancy_echo "Uninstalling old Homebrew-Cask ..."
    brew uninstall --force brew-cask
    fi

    echo "Updating Homebrew formulae ..."
    brew update

    echo "Begin Homebrew bundle install..."
    fancy_echo "Updating Homebrew formulae ..."
    brew update --force # https://github.com/Homebrew/brew/issues/1151

    fancy_echo "Begin Homebrew bundle install..."
    brew bundle --file=- <<EOF
    tap "homebrew/cask"
    tap "homebrew/cask-drivers"
    # brew
    brew "dockutil"
    brew "composer"
    brew "git"
    brew "ffmpeg"
    brew "youtube-dl"
    brew "node"
    brew "yt-dlp"
    brew "imagemagick"
    brew "php"
    brew "composer"
    brew "rbenv"
    brew "ruby-build"
    brew "rsync"
    brew "asdf"
    # osx apps
    cask "adobe-creative-cloud"
    cask "alfred"
    cask "arq"
    cask "authy"
    cask "dropbox"
    cask "firefox"
    cask "figma"
    cask "google-chrome"
    cask "hazel"
    cask "microsoft-office"
    cask "notion"
    cask "rectangle"
    cask "rightfont"
    cask "sketch"
    cask "slack"
    cask "sublime-text"
    cask "sublime-merge"
    @@ -75,72 +147,97 @@ cask "wacom-tablet"
    EOF

    echo "brew cleanup..."
    fancy_echo "Configuring asdf version manager ..."
    if [ ! -d "$HOME/.asdf" ]; then
    brew install asdf
    append_to_zshrc "source $(brew --prefix asdf)/libexec/asdf.sh" 1
    fi

    alias install_asdf_plugin=add_or_update_asdf_plugin
    add_or_update_asdf_plugin() {
    local name="$1"
    local url="$2"

    if ! asdf plugin-list | grep -Fq "$name"; then
    asdf plugin-add "$name" "$url"
    else
    asdf plugin-update "$name"
    fi
    }

    # shellcheck disable=SC1091
    . "$(brew --prefix asdf)/libexec/asdf.sh"
    add_or_update_asdf_plugin "ruby" "https://github.com/asdf-vm/asdf-ruby.git"
    add_or_update_asdf_plugin "nodejs" "https://github.com/asdf-vm/asdf-nodejs.git"

    install_asdf_language() {
    local language="$1"
    local version
    version="$(asdf list-all "$language" | grep -v "[a-z]" | tail -1)"

    if ! asdf list "$language" | grep -Fq "$version"; then
    asdf install "$language" "$version"
    asdf global "$language" "$version"
    fi
    }

    fancy_echo "Installing latest Ruby ..."
    install_asdf_language "ruby"
    gem update --system
    number_of_cores=$(sysctl -n hw.ncpu)
    bundle config --global jobs $((number_of_cores - 1))

    fancy_echo "Installing latest Node ..."
    install_asdf_language "nodejs"

    fancy_echo "brew cleanup..."
    brew cleanup

    # youtube-dl config
    mkdir ~/.config/youtube-dl && touch ~/.config/youtube-dl/config
    echo '-f bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4' >> ~/.config/youtube-dl/config
    mkdir ~/.config/yt-dlp && touch ~/.config/yt-dlp/config
    echo '-f bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4' >> ~/.config/yt-dlp/config

    # RUBY
    # https://gorails.com/setup/osx/10.15-catalina
    # https://sourabhbajaj.com/mac-setup/Ruby/

    echo "Begin Ruby config..."
    # Add rbenv to bash so that it loads every time you open a terminal
    echo 'if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi' >> ~/.zshrc
    source ~/.zshrc

    rbenv install 2.7.1
    rbenv global 2.7.1
    ruby -v

    echo "Begin OSX Settings..."
    fancy_echo "Begin OSX Settings..."

    # OSX Settings
    # reference: https://github.com/keith/dotfiles/blob/master/osx/defaults.sh

    # Disable "shake to find mouse"
    defaults write NSGlobalDomain CGDisableCursorLocationMagnification -bool true

    # Enable two button mouse
    defaults write com.apple.driver.AppleBluetoothMultitouch.mouse.plist MouseButtonMode -string "TwoButton"

    # set key repeat speed
    defaults write -g InitialKeyRepeat -int 15
    defaults write -g KeyRepeat -int 2

    # When performing a search, search the current folder by default
    defaults write com.apple.finder FXDefaultSearchScope -string SCcf

    # Dont reopen apps after shutdown
    defaults write -g ApplePersistence -bool no

    # Automatically hide and show the Dock
    defaults write com.apple.dock autohide -bool true

    # Dock setup
    defaults delete com.apple.dock persistent-apps; killall Dock

    # Change the auto-hiding Dock delay adn speed
    defaults write com.apple.dock autohide-delay -float 0.0
    defaults write com.apple.dock autohide-delay -float 0.0
    defaults write com.apple.dock autohide-time-modifier -float 0.5

    # Disable the Launchpad gesture (pinch with thumb and three fingers)
    defaults write com.apple.dock showLaunchpadGestureEnabled -int 0

    # set DNS servers
    networksetup -setdnsservers Wi-Fi 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001

    # Dock setup
    if command -v dockutil; then
    dockutil --remove all
    else
    echo "dockutil not installed, re-run after installing"
    fi

    echo "Setup process complete!"

    # MANUAL SETUP
    # install valet: https://laravel.com/docs/7.x/valet (this could be automated)
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # xcode clit tools run: "xcode-select --install"

    # install Laravel Valet
    # adobe-creative-cloud install apps
    # xcode cli tools run: "xcode-select --install"
    # git config
    # setup Dropbox
    # Alfred: link settings in dropbox
    # Sublime: link settings in dropbox with symlink
    # RightFont: link dropbox
    # RightFont: link dropbox
    # arq
    # authy
  4. maxackerman revised this gist Sep 22, 2022. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -9,6 +9,7 @@
    # files outside dropbox: downloads, documents, photos
    # bash/zsh profile
    # transmit favs
    # photobooth pics

    # reference:
    # https://github.com/thoughtbot/laptop
  5. maxackerman revised this gist Aug 16, 2022. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -57,14 +57,15 @@ cask "figma"
    cask "google-chrome"
    cask "hazel"
    cask "microsoft-office"
    cask "notion"
    cask "rectangle"
    cask "rightfont"
    cask "sketch"
    cask "slack"
    cask "sublime-text"
    cask "sublime-merge"
    cask "visual-studio-code"
    cask "transmit"
    cask "visual-studio-code"
    cask "vlc"
    cask "zoom"
  6. maxackerman revised this gist Aug 16, 2022. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -63,6 +63,7 @@ cask "sketch"
    cask "slack"
    cask "sublime-text"
    cask "sublime-merge"
    cask "visual-studio-code"
    cask "transmit"
    cask "vlc"
    cask "zoom"
  7. maxackerman revised this gist Oct 29, 2021. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,7 @@
    #!/bin/sh

    # run "sh setup.sh"

    # BACKUP BEFORE WIPE:
    # SSH keys
    # Fonts
  8. maxackerman revised this gist Oct 29, 2021. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -133,8 +133,8 @@ echo "Setup process complete!"
    # MANUAL SETUP
    # install valet: https://laravel.com/docs/7.x/valet (this could be automated)
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # xcode clit tools run: "xcode-select --install"
    # git config
    # Rectangle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup Dropbox
    # Alfred: link settings in dropbox
    # Sublime: link settings in dropbox with symlink
  9. maxackerman revised this gist Sep 21, 2021. 1 changed file with 4 additions and 2 deletions.
    6 changes: 4 additions & 2 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -51,17 +51,19 @@ cask "arq"
    cask "authy"
    cask "dropbox"
    cask "firefox"
    cask "figma"
    cask "google-chrome"
    cask "hazel"
    cask "microsoft-office"
    cask "rectangle"
    cask "rightfont"
    cask "sketch"
    cask "slack"
    cask "spectacle"
    cask "sublime-text"
    cask "sublime-merge"
    cask "transmit"
    cask "vlc"
    cask "zoom"
    # drivers
    cask "wacom-tablet"
    @@ -132,7 +134,7 @@ echo "Setup process complete!"
    # install valet: https://laravel.com/docs/7.x/valet (this could be automated)
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # Spectacle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # Rectangle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup Dropbox
    # Alfred: link settings in dropbox
    # Sublime: link settings in dropbox with symlink
  10. maxackerman revised this gist Aug 11, 2020. 2 changed files with 6 additions and 8 deletions.
    2 changes: 0 additions & 2 deletions .bash_profile → .zshrc
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,3 @@
    source ~/.profile

    export PATH=/usr/local/bin:$PATH
    export PATH="$PATH:$HOME/.composer/vendor/bin"

    12 changes: 6 additions & 6 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -4,8 +4,8 @@
    # SSH keys
    # Fonts
    # Keychain passwords
    # files outside dropbox: downloads, documetns, photos
    # bash profile
    # files outside dropbox: downloads, documents, photos
    # bash/zsh profile
    # transmit favs

    # reference:
    @@ -54,7 +54,7 @@ cask "firefox"
    cask "google-chrome"
    cask "hazel"
    cask "microsoft-office"
    cask "numi"
    cask "rightfont"
    cask "sketch"
    cask "slack"
    cask "spectacle"
    @@ -129,11 +129,11 @@ fi
    echo "Setup process complete!"

    # MANUAL SETUP
    # install valet: https://laravel.com/docs/6.x/valet (this could be automated)
    # install font manager
    # install valet: https://laravel.com/docs/7.x/valet (this could be automated)
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # Spectacle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup Dropbox
    # Alfred: link settings in dropbox
    # Sublime: link settings in dropbox
    # Sublime: link settings in dropbox with symlink
    # RightFont: link dropbox
  11. maxackerman revised this gist Aug 7, 2020. 1 changed file with 7 additions and 12 deletions.
    19 changes: 7 additions & 12 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -5,7 +5,6 @@
    # Fonts
    # Keychain passwords
    # files outside dropbox: downloads, documetns, photos
    # music itunes
    # bash profile
    # transmit favs

    @@ -39,6 +38,8 @@ brew "ffmpeg"
    brew "youtube-dl"
    brew "node"
    brew "imagemagick"
    brew "php"
    brew "composer"
    brew "rbenv"
    brew "ruby-build"
    brew "rsync"
    @@ -75,16 +76,16 @@ mkdir ~/.config/youtube-dl && touch ~/.config/youtube-dl/config
    echo '-f bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4' >> ~/.config/youtube-dl/config

    # RUBY
    # https://gorails.com/setup/osx/10.14-mojave
    # https://gorails.com/setup/osx/10.15-catalina
    # https://sourabhbajaj.com/mac-setup/Ruby/

    echo "Begin Ruby config..."
    # Add rbenv to bash so that it loads every time you open a terminal
    echo 'if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi' >> ~/.bash_profile
    source ~/.bash_profile
    echo 'if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi' >> ~/.zshrc
    source ~/.zshrc

    rbenv install 2.6.1
    rbenv global 2.6.1
    rbenv install 2.7.1
    rbenv global 2.7.1
    ruby -v

    echo "Begin OSX Settings..."
    @@ -98,10 +99,6 @@ defaults write NSGlobalDomain CGDisableCursorLocationMagnification -bool true
    # Enable two button mouse
    defaults write com.apple.driver.AppleBluetoothMultitouch.mouse.plist MouseButtonMode -string "TwoButton"

    # Trackpad: enable tap to click for this user and for the login screen
    defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
    defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1

    # set key repeat speed
    defaults write -g InitialKeyRepeat -int 15
    defaults write -g KeyRepeat -int 2
    @@ -119,7 +116,6 @@ defaults write com.apple.dock autohide -bool true
    defaults write com.apple.dock autohide-delay -float 0.0
    defaults write com.apple.dock autohide-time-modifier -float 0.5


    # set DNS servers
    networksetup -setdnsservers Wi-Fi 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001

    @@ -137,7 +133,6 @@ echo "Setup process complete!"
    # install font manager
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # mamp settings: set server ports to 80, 81, 433...
    # Spectacle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup Dropbox
    # Alfred: link settings in dropbox
  12. maxackerman revised this gist Aug 6, 2020. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -58,6 +58,7 @@ cask "sketch"
    cask "slack"
    cask "spectacle"
    cask "sublime-text"
    cask "sublime-merge"
    cask "transmit"
    cask "vlc"
  13. maxackerman revised this gist Aug 6, 2020. 1 changed file with 0 additions and 5 deletions.
    5 changes: 0 additions & 5 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -54,15 +54,10 @@ cask "google-chrome"
    cask "hazel"
    cask "microsoft-office"
    cask "numi"
    cask "nvalt"
    cask "sketch"
    cask "slack"
    cask "spectacle"
    cask "spotify"
    cask "sublime-text"
    cask "suitcase-fusion"
    cask "superduper"
    cask "tower"
    cask "transmit"
    cask "vlc"
  14. maxackerman revised this gist Dec 29, 2019. 1 changed file with 14 additions and 0 deletions.
    14 changes: 14 additions & 0 deletions .bash_profile
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    source ~/.profile

    export PATH=/usr/local/bin:$PATH
    export PATH="$PATH:$HOME/.composer/vendor/bin"

    if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi

    webmp4() {
    local maxwidth=1000
    local maxheight=1000
    for f; do
    ffmpeg -i "$f" -an -vcodec libx264 -vb 8000k -vf "scale=iw*min($maxwidth/iw\,$maxheight/ih):ih*min($maxwidth/iw\,$maxheight/ih)" -f mp4 "${f%.*}.mp4"
    done
    }
  15. maxackerman revised this gist Nov 25, 2019. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -52,7 +52,6 @@ cask "dropbox"
    cask "firefox"
    cask "google-chrome"
    cask "hazel"
    cask "mamp"
    cask "microsoft-office"
    cask "numi"
    cask "nvalt"
    @@ -138,6 +137,7 @@ fi
    echo "Setup process complete!"

    # MANUAL SETUP
    # install valet: https://laravel.com/docs/6.x/valet (this could be automated)
    # install font manager
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
  16. maxackerman revised this gist May 28, 2019. No changes.
  17. maxackerman revised this gist May 28, 2019. 1 changed file with 4 additions and 0 deletions.
    4 changes: 4 additions & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -75,6 +75,10 @@ EOF
    echo "brew cleanup..."
    brew cleanup

    # youtube-dl config
    mkdir ~/.config/youtube-dl && touch ~/.config/youtube-dl/config
    echo '-f bestvideo[ext=mp4]+bestaudio[ext=m4a]/mp4' >> ~/.config/youtube-dl/config

    # RUBY
    # https://gorails.com/setup/osx/10.14-mojave
    # https://sourabhbajaj.com/mac-setup/Ruby/
  18. maxackerman revised this gist Mar 9, 2019. 1 changed file with 5 additions and 4 deletions.
    9 changes: 5 additions & 4 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -137,7 +137,8 @@ echo "Setup process complete!"
    # install font manager
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # mamp - ports - set server ports to 80, 81, 433...
    # spectacle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup dropbox
    # connect alfred settings stored in dropbox
    # mamp settings: set server ports to 80, 81, 433...
    # Spectacle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup Dropbox
    # Alfred: link settings in dropbox
    # Sublime: link settings in dropbox
  19. maxackerman revised this gist Mar 9, 2019. 1 changed file with 20 additions and 10 deletions.
    30 changes: 20 additions & 10 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,14 @@
    #!/bin/sh

    # BACKUP BEFORE WIPE:
    # SSH keys
    # Fonts
    # Keychain passwords
    # files outside dropbox: downloads, documetns, photos
    # music itunes
    # bash profile
    # transmit favs

    # reference:
    # https://github.com/thoughtbot/laptop
    # https://github.com/tylucaskelley/setup
    @@ -90,15 +99,19 @@ defaults write NSGlobalDomain CGDisableCursorLocationMagnification -bool true
    # Enable two button mouse
    defaults write com.apple.driver.AppleBluetoothMultitouch.mouse.plist MouseButtonMode -string "TwoButton"

    # When performing a search, search the current folder by default
    defaults write com.apple.finder FXDefaultSearchScope -string SCcf
    # Trackpad: enable tap to click for this user and for the login screen
    defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
    defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1

    # set key repeat speed
    defaults write -g InitialKeyRepeat -int 15
    defaults write -g KeyRepeat -int 2

    # Disable dock magification
    defaults write com.apple.dock magnification -bool false
    # When performing a search, search the current folder by default
    defaults write com.apple.finder FXDefaultSearchScope -string SCcf

    # Dont reopen apps after shutdown
    defaults write -g ApplePersistence -bool no

    # Automatically hide and show the Dock
    defaults write com.apple.dock autohide -bool true
    @@ -107,9 +120,9 @@ defaults write com.apple.dock autohide -bool true
    defaults write com.apple.dock autohide-delay -float 0.0
    defaults write com.apple.dock autohide-time-modifier -float 0.5

    # Trackpad: enable tap to click for this user and for the login screen
    defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
    defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1

    # set DNS servers
    networksetup -setdnsservers Wi-Fi 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001

    # Dock setup
    if command -v dockutil; then
    @@ -118,9 +131,6 @@ else
    echo "dockutil not installed, re-run after installing"
    fi

    # set DNS servers
    networksetup -setdnsservers Wi-Fi 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001

    echo "Setup process complete!"

    # MANUAL SETUP
  20. maxackerman revised this gist Mar 2, 2019. 1 changed file with 0 additions and 4 deletions.
    4 changes: 0 additions & 4 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -90,10 +90,6 @@ defaults write NSGlobalDomain CGDisableCursorLocationMagnification -bool true
    # Enable two button mouse
    defaults write com.apple.driver.AppleBluetoothMultitouch.mouse.plist MouseButtonMode -string "TwoButton"

    # Trackpad: enable tap to click for this user and for the login screen
    defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
    defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1

    # When performing a search, search the current folder by default
    defaults write com.apple.finder FXDefaultSearchScope -string SCcf

  21. maxackerman revised this gist Mar 2, 2019. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -132,6 +132,6 @@ echo "Setup process complete!"
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # mamp - ports - set server ports to 80, 81, 433...
    # spectacle: remove shortcuts that conflict with photoshop undo and set as background application
    # spectacle: remove shortcuts that conflict with photoshop undo, start at login, and set as background application
    # setup dropbox
    # connect alfred settings stored in dropbox
  22. maxackerman revised this gist Mar 2, 2019. 1 changed file with 7 additions and 0 deletions.
    7 changes: 7 additions & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -90,6 +90,13 @@ defaults write NSGlobalDomain CGDisableCursorLocationMagnification -bool true
    # Enable two button mouse
    defaults write com.apple.driver.AppleBluetoothMultitouch.mouse.plist MouseButtonMode -string "TwoButton"

    # Trackpad: enable tap to click for this user and for the login screen
    defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
    defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1

    # When performing a search, search the current folder by default
    defaults write com.apple.finder FXDefaultSearchScope -string SCcf

    # set key repeat speed
    defaults write -g InitialKeyRepeat -int 15
    defaults write -g KeyRepeat -int 2
  23. maxackerman revised this gist Mar 2, 2019. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -125,6 +125,6 @@ echo "Setup process complete!"
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # mamp - ports - set server ports to 80, 81, 433...
    # spectacle - remove shortcuts that conflict with photoshop undo
    # spectacle: remove shortcuts that conflict with photoshop undo and set as background application
    # setup dropbox
    # connect alfred settings stored in dropbox
  24. maxackerman revised this gist Mar 1, 2019. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -24,6 +24,7 @@ tap "homebrew/cask"
    tap "homebrew/cask-drivers"
    # brew
    brew "dockutil"
    brew "git"
    brew "ffmpeg"
    brew "youtube-dl"
  25. maxackerman revised this gist Mar 1, 2019. 1 changed file with 3 additions and 0 deletions.
    3 changes: 3 additions & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -114,6 +114,9 @@ else
    echo "dockutil not installed, re-run after installing"
    fi

    # set DNS servers
    networksetup -setdnsservers Wi-Fi 1.1.1.1 1.0.0.1 2606:4700:4700::1111 2606:4700:4700::1001

    echo "Setup process complete!"

    # MANUAL SETUP
  26. maxackerman revised this gist Mar 1, 2019. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -37,6 +37,7 @@ brew "rsync"
    cask "adobe-creative-cloud"
    cask "alfred"
    cask "arq"
    cask "authy"
    cask "dropbox"
    cask "firefox"
    cask "google-chrome"
    @@ -50,6 +51,7 @@ cask "slack"
    cask "spectacle"
    cask "spotify"
    cask "sublime-text"
    cask "suitcase-fusion"
    cask "superduper"
    cask "tower"
    cask "transmit"
  27. maxackerman revised this gist Mar 1, 2019. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -116,7 +116,7 @@ echo "Setup process complete!"

    # MANUAL SETUP
    # install font manager
    # adobe-creative-cloud run the installer at: /usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app
    # adobe-creative-cloud run the installer '/usr/local/Caskroom/adobe-creative-cloud/latest/Creative Cloud Installer.app'
    # git config
    # mamp - ports - set server ports to 80, 81, 433...
    # spectacle - remove shortcuts that conflict with photoshop undo
  28. maxackerman revised this gist Mar 1, 2019. 1 changed file with 28 additions and 1 deletion.
    29 changes: 28 additions & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -79,12 +79,39 @@ ruby -v
    echo "Begin OSX Settings..."

    # OSX Settings
    # reference: https://github.com/keith/dotfiles/blob/master/osx/defaults.sh

    # Disable "shake to find mouse"
    defaults write NSGlobalDomain CGDisableCursorLocationMagnification -bool true

    # Enable two button mouse
    defaults write com.apple.driver.AppleBluetoothMultitouch.mouse.plist MouseButtonMode -string "TwoButton"

    # set key repeat speed
    defaults write -g InitialKeyRepeat -int 15
    defaults write -g KeyRepeat -int 2
    # auto hide dock

    # Disable dock magification
    defaults write com.apple.dock magnification -bool false

    # Automatically hide and show the Dock
    defaults write com.apple.dock autohide -bool true

    # Change the auto-hiding Dock delay adn speed
    defaults write com.apple.dock autohide-delay -float 0.0
    defaults write com.apple.dock autohide-time-modifier -float 0.5

    # Trackpad: enable tap to click for this user and for the login screen
    defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
    defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1

    # Dock setup
    if command -v dockutil; then
    dockutil --remove all
    else
    echo "dockutil not installed, re-run after installing"
    fi

    echo "Setup process complete!"

    # MANUAL SETUP
  29. maxackerman revised this gist Mar 1, 2019. 1 changed file with 0 additions and 1 deletion.
    1 change: 0 additions & 1 deletion setup.sh
    Original file line number Diff line number Diff line change
    @@ -62,7 +62,6 @@ EOF

    echo "brew cleanup..."
    brew cleanup
    brew cask cleanup

    # RUBY
    # https://gorails.com/setup/osx/10.14-mojave
  30. maxackerman renamed this gist Mar 1, 2019. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.