I created this as a reference for myself to look back to when I set up a new machine. This is specifically set up to accomodate the ruby, java and python developer. However, if you are a web developer in general, you will probably still find this set-up somewhat useful. I would just skip the RVM, Ruby and pry steps and you are good to go.
Table of contents:
- VS Code
- Intellij
- Java
- Homebrew
- RVM
- Ruby
- Pry
- Maven
- Make hidden files visible
- Node
- npm
- Docker
- Postman
- Tree
- Postgresql
- TablePlus
- CloudFoundry
- Dash
- Figma
- Magnet
- PGAdmin
- Configuring Git
Visit https://code.visualstudio.com/docs/?dv=osx
and follow the installation setup.
and now some VS Code extensions
- VSCode Ruby
- ruby-rubocop
- Ruby
- Git History
- GitLens
- Graphviz
- HTML Snippets
- ES7 React/Redux/Graphql
- Docker
- Code Runner
and now some VS Code configurations
Hit shift => command => p
and then type in Preferences: Open Settings (JSON)
and hit enter
Replace the contents of the file with:
{
"editor.tabSize": 2,
"liveServer.settings.donotShowInfoMsg": true,
"files.associations": {
"*.js": "javascriptreact",
"*js.erb": "javascript"
},
"code-runner.runInTerminal": true,
"ruby.codeCompletion": "rcodetools",
"emmet.includeLanguages": {
"erb": "html"
},
}
and make sure its your default code editor by doing the shift command p
command and then typing shell command, and selecting the Install 'code' command
If it doesnt work...
do the following and then try the previous step.
sudo rm /usr/local/bin/code
Visit https://www.jetbrains.com/idea/download/#section=mac
and download the Community Edition (unless you have bought the Ultimate Edition)
## Intellij Plugins
To install plugins, cmd -> ,
to open the preferences window, and select plugins, followed by the marketplace tab.
- Python Community Edition
- GitToolBox
- Jump to line
- EduTools
- Extra Icons
- Rainbow Brackets
- Maven helper
- VSCode Keymap
(for the vscode keymap, you must also go to
cmd -> ,
and select keymap, and select vscode macos from the dropdown menu)
Visit https://www.oracle.com/java/technologies/downloads/#jdk17-mac
and download the Standard Edition.
Click on the DMG installer as it does the process automatically.
If you are on Apple silicon, click the ARM
If on intel, just the x64.
Running git --version
will prompt you to download git on mac devices running Mavericks and up
Visit this downloads page
Follow the instructions here:
http://burnedpixel.com/blog/setting-up-git-and-github-on-your-mac/
After following those instructions, you probbaly created a keychain passcode. To ensure you dont have to input it for EVERY action, you can save it on your machine following this:
https://stackoverflow.com/questions/10032461/git-keeps-asking-me-for-my-ssh-key-passphrase
Open your terminal and run;
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Check everything went ok by running
brew doctor
and that you have the latest version
brew update
To find some more info on Brew, visit https://brew.sh/
From your terminal, run
\curl -L https://get.rvm.io | bash -s stable
And check it works through this;
type rvm | head -n 1
If you get some errors, try the following:
https://stackoverflow.com/questions/11677771/rvm-command-not-found-mac-ox
rvm use ruby --install --default
gem install pry
From your terminal, run:
brew install node
From your terminal, run:
brew install npm
and to make sure you are not attacked by a virus outbreak, if it were to happen
From your terminal, run:
brew cask install docker
and once thats finished, run:
docker run hello-world
To see that everything works!
From your terminal, run:
brew install redis
redis-server --daemonize yes
From your terminal, run:
brew install yarn
From your terminal, run:
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh | bash
source ~/.nvm/nvm.sh
Visit the postman downloads page
From your terminal, run:
brew install tree
From your terminal, run:
brew install postgresql
More info, visit https://www.postgresql.org/download/macosx/
and start it by running:
pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start
OR
brew services start postgresql
and continue the setup by tapping in:
psql postgres
Or set up with your own user
whoami
postgres=# CREATE DATABASE "your_user_name_here";
Or set up your main generic with admin privileges:
CREATE ROLE postgres WITH LOGIN PASSWORD 'password';
ALTER ROLE newUser CREATEDB;
Then quit and login with the new credentials:
/q
psql postgres -U {userName you created last step, ie postgres};
Run: brew install maven
and check it completed successfully by:
mvn --version
Make hidden files visible
Open finder, and press: command-shift-dot
Hidden directories should be now visible
Visit: https://tableplus.com/download
From your terminal, run:
brew install cloudfoundry/tap/cf-cli
Visit: https://kapeli.com/dash
Visit: https://www.figma.com/downloads/
Visit the app store
Visit: https://www.pgadmin.org/download/
- JSON Formatter
- Lighthouse
- Grammarly
- Disable JavaScript
- React Developer Tools
- Ad Blocker
- Allow CORS
Go to https://toolbelt.heroku.com/osx
and download the CLI
From your terminal, type..
vim ~/.gitconfig
And inside the following file that pops up, put in the following things. These are only nice-to-haves and are not essential in your development.
[user]
name = {Your Name}
email = {Your Email}
[core]
editor = /usr/bin/vim
[push]
default = current
This is great: http://www.preparetocode.io/mac/essential/ruby.html