You have a new MacBook! Congrats!
You need to setup your mac to be Developer Ready and don't know what to do. You are in the right place. I have compiled a list of installation scripts for a typical Developer to kick start a Developer Machine.
macOS Updates
Before installing any applications you require, it is a good idea to update the Operating System. As much as possible, I try to have the latest version of the MacOS with patches.
XCode
First step, you need to install XCode which is Apple's integrated development environment for MacOS. You can download it in the Apple Store free of charge. There is a command line instruction to install xcode. Open a new terminal and type the code below.
xcode-select --install
Homebrew
I pretty much use Homebrew
or brew
to install anything on my MacBook and Linux Machines. Run the following commands to download and install brew
and upgrade it, though there should not be anything to upgrade. No harm doing though.
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew upgrade
Python 3 and JQ
Next to Java, Python is probably my next go to programming language. I used python a lot to build client tools and serverless applications. JQ
is a tool to parse JSON Strings and I predominantly use this with python and aws. VirtualEnv
is my favorite environment configuration for python. Python virtualization is a must if you are going to develop using python. Python is also a requirement for some client tools like awscli
.
brew install python3
curl https://bootstrap.pypa.io/get-pip.py | python3
pip install virtualenv
brew install jq
AWS
I work mostly with AWS Cloud hence I require AWS Client that uses Python. If you are not in AWS, you may skip this part. This command will help you install and upgrade your aws client. I have both added awscli
and awscli-local
.
brew install awscli
brew link awscli --overwrite
pip install awscli-local
Docker Desktop
Since Mac-OS is not a linux distro, it is impossible to install docker base binaries. Don't fear though, docker created a desktop installer for mac here.
Localstack
Since AWS is a paid service, creating infrastructure usually cost $$$ if you are unable to use the free-tier. To test out my infrastructure-as-code scripts, I spin up a Mock AWS Service called localstack
.
pip install localstack
Terminal
MacOS' terminal is nice, no complains about it. As a developer, sometimes I would like to work on multiple Terminals but within the same window. Hence, I require some Split functionality and iTerm2
has that capability. ZSH is the prefered console of MacOS terminal nowadays.
chsh -s /bin/zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
brew install iterm2
NodeJS
As much as I don't want to tackle NodeJS, this programming language is pretty much use anywhere from backend processing to UI development using frameworks such as react
or angular
or vue
. Somehow, I got the hang of this programming framework as well. I've been using this in my side projects. Yarn
is my favourite package manager. You can install any PM you want.
brew install node
brew install nvm
brew install yarn
Serverless Framework
Between AWS Severless Application Model (SAM
) and Serverless Framework (SLS
), I prefer the latter. Both framework patterns their syntax from AWS Cloudformation, but I firmly believe Serverless Framework is more mature. Don't get me wrong, I love AWS
. SLS is my own choice.
curl -o- -L https://slss.io/install | bash
Infrastructure As Code
I've been using Cloudformation ever since I had moved to the cloud. But when I've learned Terraform
, I seldom touch Cloudformation unless I am working with SLS
above.
brew install terraform
Git and Git Flow
In one way or another, you might be using a Source Code Versioning System like github
or gitlab
. A git
client is required.I have added a plugin called git flow
for the purpose of following a release framework.
brew install git
brew install git-flow
Database Connectivity Tool
We use databases to persist data. I've used a lot of databases in my career, from MS SQL Server
to Oracle
to Postgres
or MySQL
. I don't have a clear favourite but for this tutorial, I will go with the easiest postgres
. Take note, this is only a connection tool, you may ask how do you install your database? As I've mentioned above, I would containerise my databases, read it here.
brew install libpq
Miscellaneous Tools
The rest of the apps in this code block are optional. Some are required due to the fact that I am using it like gpg for encryption and java being my favourite programming language. It is to your discretion if you will install them or not. Atom
here is a good IDE but since Microsoft bought Github, it is not being developed anymore and Visual Studio Code Express is the preferred IDE.
brew install atom
brew install kubectx
brew install gpg
brew install blackbox
brew install java
brew cask install eclipse-java
brew cask install postman
brew install macpass
brew install credstash
Full Script
For all the apps that can be installed using the terminal, I've compiled a full list below.
# Install Homebrew - preferred apps installation manager
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew upgrade
# Install Python 3
brew install python3
# update pip
curl https://bootstrap.pypa.io/get-pip.py | python3
# install virtualenv for python, if you dont use python no need to install this
pip install virtualenv
# install jq
brew install jq
# Install AWS Client using Homebrew
brew install awscli
# if there is already an install client, ovewrite its softlink
brew link awscli --overwrite
# install aws client for localstack
pip install awscli-local
# install docker using docker installer
brew cask install docker
# install localstack
pip install localstack
# preferred mac terminal
brew install iterm2
# CHANGE TO zsh, if you want too.
chsh -s /bin/zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
# all about NODEJS
brew install node
brew install nvm
brew install yarn
# if your office has certificate restrictions, you may want to remove ssl restriction
yarn config set strict-ssl false
# for AWS lambda deployment, we prefer Serverless Framework
curl -o- -L https://slss.io/install | bash
# for Infrastructure as Code
brew install terraform
#install git
brew install git
# install git flow
brew install git-flow
# postgres tool
brew install libpq
# this is my preferred editor, if you dont like it dont install it
brew install atom
# some passwords used for OPs are in keepass and macpass is the keepass version for mac
brew install macpass
# we do use kubernetes, this is required to connect to it
brew install kubectx
# install gpg
brew install gpg
# install Java
brew install java
brew cask install eclipse-java
brew cask install postman
# password tools
brew install blackbox
brew install credstash
Top comments (1)
Wonderful ❤