Created
September 4, 2013 10:12
-
-
Save bazscott/6435157 to your computer and use it in GitHub Desktop.
Show TODOs And FIXMEs As Warnings in Xcode
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Select the project in Project Navigator | |
- Open the Build Phases tab | |
- Add a new "Run Script" build phase | |
- Insert the following script: | |
KEYWORDS="TODO:|FIXME:|\?\?\?:|\!\!\!:" | |
find "${SRCROOT}" \( -name "*.h" -or -name "*.m" \) -print0 | xargs -0 egrep --with-filename --line-number --only-matching "($KEYWORDS).*\$" | perl -p -e "s/($KEYWORDS)/ warning: \$1/" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment