Skip to content

Commit

Permalink
Merge branch 'master' of github.com:psynaptic/php-drupal.tmbundle int…
Browse files Browse the repository at this point in the history
…o 7.x-1.x

* 'master' of github.com:psynaptic/php-drupal.tmbundle:
  Patched coder_format using patch from original post of 853582: Postprocessor to enforce 'elseif' in place of 'else if'.
  Added coder_format and 'Code format' command on ⌘ ⌥ ⇧ C.
  Added ddebug_backtrace() snippet.
  • Loading branch information
webflo committed Jun 14, 2011
2 parents 592def8 + 47bce39 commit 05762f3
Show file tree
Hide file tree
Showing 4 changed files with 1,427 additions and 0 deletions.
29 changes: 29 additions & 0 deletions Commands/Coder format.tmCommand
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>beforeRunningCommand</key>
<string>nop</string>
<key>command</key>
<string>#!/usr/bin/env php
&lt;?php
require $_SERVER['TM_BUNDLE_SUPPORT'] . '/scripts/coder_format/coder_format.inc';
$document = file_get_contents('php://stdin');
print coder_format_string_all($document);
</string>
<key>input</key>
<string>selection</string>
<key>keyEquivalent</key>
<string>~@C</string>
<key>name</key>
<string>Coder format</string>
<key>output</key>
<string>replaceSelectedText</string>
<key>scope</key>
<string>source.php</string>
<key>uuid</key>
<string>72F07D9D-FA46-4FD8-BE6B-C98F921BC0DD</string>
</dict>
</plist>
16 changes: 16 additions & 0 deletions Snippets/ddebug_backtrace.tmSnippet
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>content</key>
<string>ddebug_backtrace();</string>
<key>name</key>
<string>ddebug_backtrace</string>
<key>scope</key>
<string>source.php</string>
<key>tabTrigger</key>
<string>d</string>
<key>uuid</key>
<string>0C521CF6-7E58-47D9-B3F5-DB7B8CB529BD</string>
</dict>
</plist>

0 comments on commit 05762f3

Please sign in to comment.