forked from petrowsky/filemaker.tmbundle
-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathTidy*.tmCommand
37 lines (34 loc) · 1.06 KB
/
Tidy*.tmCommand
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?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>#
# DESCRIPTION
# Pretty prints FileMaker calculation. Mostly just cleans up whitespace and indentation.
# Should respect your settings for tab width and soft tabs
# Does NOT perform any validation.
# Field names must not contain % or ? or double spaces
#
# CREDIT
# Original perl script provided courtesy of Debi Fuchs, debi@aptworks.com
#
TEXT="$(ruby -e 'puts STDIN.read')"
SCRIPT_PATH="$TM_BUNDLE_SUPPORT$TM_PATH_TIDY"
perl "$SCRIPT_PATH" "$TEXT" "$TM_TAB_SIZE" "$TM_SOFT_TABS"</string>
<key>input</key>
<string>selection</string>
<key>keyEquivalent</key>
<string>^H</string>
<key>name</key>
<string>Tidy</string>
<key>output</key>
<string>replaceSelectedText</string>
<key>scope</key>
<string>source.filemaker</string>
<key>uuid</key>
<string>FA742894-F5C0-4E13-BC0E-F1D38416E084</string>
</dict>
</plist>