Skip to content

Instantly share code, notes, and snippets.

@ronaldbradford
Last active November 15, 2022 15:57
Show Gist options
  • Save ronaldbradford/f901c57a2f953447cbbb287d9bc73066 to your computer and use it in GitHub Desktop.
Save ronaldbradford/f901c57a2f953447cbbb287d9bc73066 to your computer and use it in GitHub Desktop.
MacOS Installation

Commands

  chmod +x ./install.sh
  ./install.sh
  # Note some commands are interactive

Installed

  • brew
  • wget
  • jq
  • atom
  • iterm2
  • pyenv
  • Python 3.10, 3.11
  • AWS cli V2
  • GCP cli
  • github CLI

Configuration

  • Screenprint location
  • SSH Key
  • GitHub

Manual Things

System Preferences - Trackpad

  • disable scroll direction - natural System Preferences - Keyboards
  • Detect System Preference - Mouse
  • Detect
  • disable scroll direction - nature
  • enable secondary click

iTerm - Profiles - Default

  • General Name Dark
  • General Shortcut - Cmd-Ctrl-A
  • Window Columns 120 Rows 40
  • Window - tick force open new window
  • Terminal - Unlimited Scrollback
  • Terminal - Silence Bell
  • Session - Automatically log sessions to ~/log Duplicate Profile
  • General Name White
  • Color - Presets - Light Background
  • General Shortcut - Cmd-Ctrl-B
#!/usr/bin/env bash
# Bash
chsh -s /bin/bash
echo "export NAME='Your Name'
export EMAIL='email@example.com'" >> ~/.bash_profile
# iTerm Logging
mkdir ${HOME}/log
# Brew
xcode-select --install
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
echo '# Set PATH, MANPATH, etc., for Homebrew.' >> ${HOME}/.profile
echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ${HOME}/.profile
source ~/.profile
brew update
brew upgrade
brew install wget
brew install jq
brew instal atom
brew install --cask iterm2
# Screenshots
mkdir ~/screenprint
defaults write com.apple.screencapture location ~/screenprint
# Python
curl https://pyenv.run | bash
echo "export PYENV_ROOT=\$HOME/.pyenv
command -v pyenv >/dev/null || export PATH=\"\$PYENV_ROOT/bin:\$PATH\"
eval \"\$(pyenv init -)\"
">> ~/.profile
source ~/.profile
pyenv install 3.10.8
pyenv install 3.11.0
pyenv versions
pyenv global 3.10.8
pyenv versions
pip install pandas geopandas ipython jupyter
# AWS Cloud
curl "https://awscli.amazonaws.com/AWSCLIV2.pkg" -o "AWSCLIV2.pkg"
sudo installer -pkg AWSCLIV2.pkg -target /
rm AWSCLIV2.pkg
which aws
aws --version
aws configure # Interactive Response Required
cat ~/.aws/config
cat ~/.aws/credentials
echo "cli_pager=cat" >> ~/.aws/config
aws ec2 describe-regions
# GCP Cloud
wget https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-cli-408.0.1-darwin-arm.tar.gz
tar xvfz google-cloud-cli-408.0.1-darwin-arm.tar.gz
./google-cloud-sdk/install.sh
./google-cloud-sdk/bin/gcloud init
gcloud cheat-sheet
rm google-cloud-cli-408.0.1-darwin-arm.tar.gz
gcloud auth list
gcloud config list
gcloud projects list
gcloud config set project playground
gcloud compute regions list
# Setup Github SSH Access
ssh-keygen -t ed25519 -C "${EMAIL}" -f ~/.ssh/id_ed25519
pbcopy < ~/.ssh/id_ed25519.pub
# See https://docs.github.com/en/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account
open https://github.com/settings/ssh/new
git config --global user.name "${NAME}"
git config --global user.email "${EMAIL}"
## Configure github CLI
brew install gh
gh auth login
gh config set -h github.com git_protocol ssh
gh config list
# Test out github access
mkdir -p ~/git
cd ~/git
gh repo clone https://github.com/github/homebrew-gh
cd homebrew-gh
git log
# Audio transcribing
# https://github.com/openai/whisper
brew install audacity
brew install ffmpeg
pip install git+https://github.com/openai/whisper.git
whisper --help
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment