Install Homebrew: http://brew.sh Homebrew is a package manager for OS X. It is recommended you installed it anyway.
Download Segger J-Link software, and install the pack.
Connect your J-Link to computer, and the target board/chip.Find your installation path ~/Seggar/JLink/, and run ./JLinkExe
After JLink> command prompts appear, you can start to use JLink commands.
Popular JLink commands:
device - select a device
if - select interface, SWD or JTAG
speed - interface comm rate, 4000Hz default
loadfile - flash the bin/hex file into target
r - reset target
q - quit JLink command line
For a full reference of JLink commands, please check :
https://www.segger.com/admin/uploads/productDocs/UM08001_JLink.pdf