GithubHelp home page GithubHelp logo

mac-programmer-setup-guide's Introduction

Mac Programmer's Setup Notes

1. Install the Latest Command Line Tools

xcode-select --install
softwareupdate --all --install --force

2. Install Homebrew

First,

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

After downloading, add homebrew to your path

echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> /Users/ccm/.zprofile
eval "$(/opt/homebrew/bin/brew shellenv)"

Then open a new terminal, and check the installation with:

brew doctor

Install the latest version of Git

brew update
brew install git

Install Github Command Line Tools (if you use Github)

First,

brew update
brew install gh
gh auth login

then follow the instructions to login to Gihub.com and authenticate your computer.


Config your git user.name and user.email

git config --global user.name "Mona Lisa"
git config --global user.email [email protected]

Install Oh My Zsh

sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Some plugins I like:

  1. zsh-autosuggestions

    git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
    
  2. zsh-syntax-highlighting

    git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

Install Pyenv and Python

First,

brew update
brew install pyenv

Then update your zsh config files

echo "alias brew='env PATH="${PATH//$(pyenv root)\/shims:/}" brew'" >> ~/.zshrc
echo 'eval "$(pyenv init --path)"' >> ~/.zprofile
echo 'eval "$(pyenv init -)"' >> ~/.zshrc

Install libraries required to install python

brew install openssl readline sqlite3 xz zlib

To see the versions of Python that can be installed,

pyenv install -l

Choose the version you want, for example 3.9.9, and install it

pyenv install 3.9.9

Create a new terminal window, and check your installation

python --version

Setup a Python Virtual Environment

pip install -U pip
pip install virtualenv
mkdir .virtualenvs
virtualenv env_name

I like to add an alias to .zshrc to activate my virtual environment e.g.,

alias activate='source /home/.virtualenvs/env_name/bin/activate'

Install rbenv

brew install rbenv

Check which ruby versions are available to install

rbenv install -l 

Install ruby e.g.,

rbenv install 3.0.3
rbenv global 3.0.3
echo 'eval "$(rbenv init - zsh)"' >> ~/.zshrc

start a new shell and check you have the right ruby version in your path

ruby -v

Install jekyll

gem install --user-install bundler jekyll

if you get a path error, export the path e.g.,

echo 'export PATH="/Users/ccm/.local/share/gem/ruby/3.0.0/bin:$PATH"' >> ~/.zshrc

create a new jekyll project to test everything is working

gem install bundler jekyll
jekyll new my-awesome-site
cd my-awesome-site
bundle exec jekyll serve
# => Now browse to http://localhost:4000

If there is an error about webrick

bundle add webrick

Install Visual Studio Code

download the release version here

or get the insiders version here

mac-programmer-setup-guide's People

Contributors

cmorace avatar

Stargazers

Cladis Creo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.