Posts

Showing posts with the label Mac / OSX

Flush / Reset DNS Cache on Mac OS X

Image
If you want to reset / flush the DNS cache on Mac OS X Mavericks or Yosemite use this command: dscacheutil -flushcache

Git branch name in your prompt

When you want to get something similar like idea:~/my/project/hybris/order-service (develop)   as your Bash prompt on a Mac or perhaps some other Unix OSs — where "( develop )" could be your  currently checked out Git branch — add this PS1='\h:\[\e[0;31m\]\w\[\e[m\]`__git_ps1` '   or  PS1='\h:\[\e[0;31m\]\w\[\e[m\] \e[1;31m\]$(__git_ps1 %s)\e[m '  to your ~/.bash_profile Alternatively you could use PS1='`__git_ps1` ' just to see the branch name.

How to install a *.pkg file from the command line (CLI) on Mac OS X

sudo installer -pkg installer-osx-amd64.pkg -target LocalSystem ...where  installer-osx-amd64.pkg is the package file that is installed and LocalSystem  the default installation target.