madeleinel / dev_env_setup

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dev environment setup

Initial Setup

  • Install Atom
  • Install iTerm2
  • Hush login message - touch ~/.hushlogin
  • Install Homebrew
  • Install ZSH - brew install zsh
  • Change shell - chsh -s /usr/local/bin/zsh OR chsh -s /bin/zsh - run atom /etc/shells to check which path is included in the list of acceptable shells. If neither are included, add it to the bottom of that list.
  • Install Oh-my-zsh - curl -L http://install.ohmyz.sh | sh

Add CLIs and Short Commands

  • Enable the command atom <file_name> in the terminal: In Atom, go to Menu and click Install Shell Commands
  • Add the Heroku CLI: brew tap heroku/brew && brew install heroku - More info

Terminal Customisation

  • Configure the terminal setup in ~/.zshrc
    • Set terminal theme (showing current branch etc) - ZSH_THEME="agnoster" - More info
    • Set default user so it’s not displayed in the terminal window - DEFAULT_USER="madeleinelinder"
  • Configure the terminal setup in ~/.oh-my-zsh/themes/agnoster.zsh-theme
    • Set it to only display the last two steps of the directory path - set prompt_dir() to prompt_segment blue black '%2~'
  • Install Powerline font - list of available fonts
# Clone the font repo
$ git clone https://github.com/powerline/fonts.git --depth=1
# Run the installation script
$ cd fonts
$ ./install.sh
# Tidy up the directory
$ cd ..
$ rm -rf fonts
  • Change settings in iTerm Preferences > Profiles
    • Set the font: Text > Change font > 12pt Roboto Mono for Powerline
    • Change colour scheme: Colors > Colour Presets > Pastel Dark Background && change ANSI blacks to 100% Black
    • Set the home directory: General > Working directory > Change to /Users/madeleinelinder/code
  • Set up syntax highlighting
    • To install: cd ~/.oh-my-zsh && git clone git://github.com/zsh-users/zsh-syntax-highlighting.git
    • To enable: Add source ~/.oh-my-zsh/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh to the end of ~.zshrc and then restart the terminal and run command source ~/.zshrc

Authentication

Connect the terminal to your GitHub account using SSH keys.

Git Config

Update the content in the git config file to ensure that GitHub commits are being assigned to the right user.

  • Update the name - git config --global user.name "<Full Name>"
  • Update the email address - git config --global user.email "<email_address>"

Heroku Config

Set Heroku CLI credentials to enable connecting to the Heroku account through the terminal.

  • heroku login > Press any key to open the browser > Return to the terminal > Should see message Logged in as <email_address>
  • Run cat ~/.netrc to confirm that the login credentials have been added to that file

Setup of Further Tools & Software

# Build docker containers
$ docker-compose build
# Start docker containers
$ docker-compose up -d
  • Postgres: brew install postgresql and `brew services start postgresql
  • Node & npm: brew install node
  • React Native: brew install node && brew install watchman && npm install -g react-native-cli
  • Xcode: download through the App Store
  • Android Studio: brew cask install android-studio

About

License:MIT License


Languages

Language:Shell 100.0%