Created
July 29, 2010 17:33
-
-
Save chrisbloom7/498742 to your computer and use it in GitHub Desktop.
Textmate command for PHP_Beautifier
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
# Runs PHP_Beautifier on the current document. | |
# See http://beautifyphp.sourceforge.net/ for more info. | |
# Add this as a new command in TextMate | |
# I used the following additional command settings: | |
# Save: Nothing | |
# Input: Document ("Selected Text or", note PHP_Beautifier | |
# only works on complete PHP documents) | |
# Output: Replace Document | |
if [[ "$TM_SOFT_TABS" == "YES" ]]; then | |
_TABS="-s$TM_TAB_SIZE" | |
else | |
_TABS="-t$TM_TAB_SIZE" | |
fi | |
php_beautifier $_TABS "$TM_FILEPATH" - |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment