Skip to content

Instantly share code, notes, and snippets.

@saas786
Forked from jagdeepsingh/README.md
Created March 30, 2020 11:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save saas786/842fc4924c392651b9d93a157e045ac9 to your computer and use it in GitHub Desktop.
Save saas786/842fc4924c392651b9d93a157e045ac9 to your computer and use it in GitHub Desktop.
Set up macOS Catalina 10.15 with development tools

Set up macOS Catalina 10.15

Contents:

1 git

1.1 Installation

Open the terminal and type git. If it not installed, you will see a dialog box with a button to "Install" it. Click on the button and git will be installed in a couple of minutes.

$ git --version
git version 2.20.1 (Apple Git-117)

1.2 Configure

Configure the username and email to be used.

$ git config --global user.name jagdeepsingh
$ git config --global user.email jagdeepsingh.125k@gmail.com

Generate SSH key. When prompted to select file location and to enter passphrase, leave it empty.

$ ssh-keygen -t rsa -b 4096 -C 'jagdeepsingh.125k@gmail.com'
Generating public/private rsa key pair.
...
Your identification has been saved in /Users/jagdeepsingh/.ssh/id_rsa.
Your public key has been saved in /Users/jagdeepsingh/.ssh/id_rsa.pub.
...

Copy the contents of file ~/.ssh/id_rsa.pub and add it to "SSH Keys" under "Github > Settings > SSH and GPG Keys".

$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# Enter your mac password when prompted.

$ brew -v
Homebrew 2.1.11
Homebrew/homebrew-core (git revision f8ea; last commit 2019-09-30)
$ brew install rbenv

$ rbenv -v
rbenv 1.1.2

$ rbenv init
# You will find a list of intructions here. Follow them to set up rbenv shell integration.

Close your terminal window and open a new one for changes to take effect.

Verify that rbenv is properly set up by running:

$ curl -fsSL https://github.com/rbenv/rbenv-installer/raw/master/bin/rbenv-doctor | bash
Checking for `rbenv' in PATH: /usr/local/bin/rbenv
Checking for rbenv shims in PATH: OK
Checking `rbenv install' support: /usr/local/bin/rbenv-install (ruby-build 20190828)
Counting installed Ruby versions: none
  There aren't any Ruby versions installed under `/Users/jagdeepsingh/.rbenv/versions'.
  You can install Ruby versions like so: rbenv install 2.2.4
Checking RubyGems settings: OK
Auditing installed plugins: OK
$ rbenv install 2.6.4

Check the installed ruby versions.

$ rbenv versions
* system (set by /Users/jagdeepsingh/.rbenv/version)
  2.6.4

Use a specific version.

$ rbenv local 2.6.4

Check the current active version.

$ rbenv version
2.6.4 (set by /Users/jagdeepsingh/code/work/.ruby-version)

See full rbenv cheetsheet for more commands.

$ gem install bundler

$ bundler -v
Bundler version 2.0.2

Install "Atom" and then install shell commands (e.g. atom) by clicking on "Atom > Install Shell Commands".

7 Databases

7.1 MySQL

$ brew install mysql

$ mysql --version
mysql  Ver 8.0.18 for osx10.15 on x86_64 (Homebrew)

Follow the instructions to set a password for root user and then get the service running.

Test successful setup by running:

$ mysql -uroot -p
Enter password: 
$ brew install postgres

$ postgres --version
postgres (PostgreSQL) 11.5

Create role "postgres" by running:

$ /usr/local/opt/postgres/bin/createuser -s postgres
$ brew tap mongodb/brew

$ brew install mongodb-community

Test the installation success by running mongo in terminal.

$ brew install node

$ npm -v
6.11.3

$ node -v
v12.12.0
$ brew install yarn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment