Skip to content

Instantly share code, notes, and snippets.

@Pen-y-Fan
Created August 28, 2024 13:03
Show Gist options
  • Save Pen-y-Fan/7ecb3ed19c417d94d17e93582622178c to your computer and use it in GitHub Desktop.
Save Pen-y-Fan/7ecb3ed19c417d94d17e93582622178c to your computer and use it in GitHub Desktop.
Setup Mac for Development

My note on setting up my Mac for software development.

Feel free to google the suggestions and choose your preferred setup.

Setup Mac for Development

Non development

  • Chrome - with extensions, add blocker etc.
  • Firefox dev - secondary browser
  • Franz.app - messaging aggregator app, WhatsApp, Slack messages (for android SMS) etc
  • Alfrid - app launcher, commands and clipboard. Workflows use Raycast
  • keyboard - function keys as standard function keys and snippet manager
  • home and end key - google Make home & end keys behave like Windows on Mac
  • Bear for notes
  • Flycut - clipboard manager
  • Dato - calendar app
  • iStatMenus - monitor fans and cpu etc
  • forcast bar - weather
  • Dropbox - file storage
  • photoshop and lightroom
  • screenflow
  • final cut pro
  • vlc
  • AppCleaner - uninstall apps
  • DaisyDisk - GUI for disk usage
  • Switch res x - change resolution but keep high DPI for text
  • Figma - design tools
  • iconjar - select design icons
  • BetterTouchTool - global keyboard shortcuts (command F for finder)
  • bartender - control menu bar
  • caffeine - keep computer awake (stop sleep mode)
  • zoom
  • Numi - calculator
  • ms office
  • Setapp - subscription based service

Development Desktop Software

  • VS Code
  • PhpStorm
  • iTerm - terminal - next episode
  • Sequel Ace - MySQL client
  • TablePlus - Postgress and Sqlite
  • Filezilla - FTP client
  • Insomnia - rest client - API calls
  • HELO - local email client (mailhog)
  • Tinkerwell
  • xcode -
  • docker
  • valet
  • PHP monitor

iTerm Setup

  • toggle key preference > hot key > ^`
  • Profile: General tab, directory /Users/dre/Code
  • Appearance > Theme > Minimal
  • Font: Profiles > Text > Font -> Fira Code 16 100 150
  • Colors: MaterialDark (search online)

ohmyzsh

  • search on github, use curl to download

Edit the config file:

code ~/.zshrc

See alias e.g. git: g for git g, ga for git add etc

Syntax highlighting: zsh-osx-syntax-highlighting

Autocompletion: zhs-autosuggestions

Aliases

alias hostfile="sudo code /etc/hosts"
alias server="php -S localhost:8888"
alias publickey="pbcopy < ~/.ssh/id_rsa.pub"

# Laravel
alias a="php artisan"
alias tinker="php artisan tinker"
alias mfs="php artisan migrate:fresh --seed"
alias phpunit="vendor/bin/phpunit"
alias pest="vendor/bin/pest"
alias vapor="vendor/bin/vapor"

# Git
alias nah="git reset --hard && git clean -df"
alias gs="git status"
alias ga="git add -A"
alias gc="git commit"
alias gp="git push origin master"
alias gl="git log -- graph ... google it!!"

# Composer
ali as cu="composer update"
alias cda="composer dump-autoload"


# Filesystem
alias o="open ."
alias c="code ."

# Paths (for composer and laravel )
export PATH="$HOME/.composer/vendor/bin:$PATH"
export PATH="/usr/local/bin:$PATH"

To check if an app is installed

e.g. vs code

which code

Follow the instructions on code on how to add code to the PATH

To suppress the last login info when opening a file:

touch ~/.hushlogin

CLI tooling

Homebrew

See the brew homepage to install

PHP

brew install [email protected]

PHP packages, view the installed packages:

pecl list

Install:

pecl install xdebug

Composer

See homepage and follow instructions

Copy to /usr/local.bin/composer

Laravel

Follow instructions on Laravel page install laravel globally

Laravel Valet

Follow the instructions to install, including valet park

MySQL

brew install mysql

See BDngin for all-in-one database version management tool

node

Follow instruction on node.js.org page

Can be installed using brew.

trash-cli

delete a file or folder safely

hub

  • <hub.github.com>

auto create a github project based on the local git repo.

git init
ga
gc -m "initial commit"
hub create -p
gp

git

Install using brew brew install git

Configure global settings

git config --global --edit

Add name, email and global excludesfile = /Users/dre/.gitignore

Expose

Open source tunnel app

Useful for testing webhooks and APIs on mobile

VS Code

Install following the instructions

Theme: Community Material Theme Icons: Material Icon Theme

  • Better PHPUnit - needs keybindings

..etc..

Chrome Extensions

  • Awesome Screenshot & recorder
  • Google Docs Offline
  • JSON Viewer - beautiful and customizable JSON highlighter
  • Octotree - GitHub tree navigation
  • PrettyPrint - CSS & JS formatter/highlighter
  • ProductivityTab - customize chrome dashboard
  • Tag Assistant (by Google) - turn off when not in use - helps Google Analytics
  • uBock Origin - add blocking
  • View Image Info (properties)
  • Wappalyzer - identify web technologies

Boost your design skills instantly for free with Raycast

Boost your design skills instantly for free with Raycast - YouTube by A Better Computer

Get Raycast

  • 0:00 - Welcome!
  • 0:48 - Generate Random Data
  • 2:10 - Lorem Ipsum
  • 2:40 - The Office Quotes
  • 2:55 - Google Translate
  • 3:39 - Formula 1
  • 4:21 - Clipboard History
  • 5:05 - Render Color
  • 6:19 - Unsplash
  • 7:48 - Run Shortcuts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment