Archive for the ‘OS X’ Category

Manually set a breakpoint in safari (and in chrome on OSX)

0 Comments

To manually set a breakpoint add the line ‘debugger;’

So if I have some js in an onclick, and I’m trying to look at the scope there, just add ‘debugger;’ to the onclick.


click me

Make safari open links in new tab

0 Comments

To force safari to open links that would otherwise have been opened in a new window (target=_blank) to open in new tabs instead:

  • defaults write com.apple.Safari TargetedClicksCreateTabs -bool true

Changing screenshot file location in osx

0 Comments

  • $ defaults write com.apple.screencapture location /Users/ashton/Pictures/Screenshots/
  • $ killall -HUP SystemUIServer