Xcode/iOS license reminder

As a Homebrew user I find myself searching on how to agree to the new Xcode/iOS license after every Xcode update when I into the following error message on brew update:

Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo.

Error: Failure while executing: git checkout -q master

So as a quick reminder for myself; this pops up the new license to agree to:

sudo xcrun cc

UPDATE, 23 Oct 2015: it seems that Xcode > 7.0 now prints out the command you can run:

sudo xcodebuild -license