System is OS X 10.4.7. TM version 1.5.3 (1200). Same error occurs on another system with unknown information (we corresponded over email...).
To reproduce: 1. Create a new command. Enter a short, non-shell script printing out '$' at some point. Ex: #!/usr/bin/env python print "test: $SIG{}" 2. Make sure the output mode is set to "Insert as Snippet". 3. Run command in a document.
Expected result: Document shows the result of the program. e.g. "test: $SIG{}"
Actual result: Document shows result with characters removed following and including '$'. e.g. "test: {}" Note that the removal stopped at what is generally a "special" character.
Comments: The expected result occurs when the output method is changed to "Insert as Text" or "Replace selected Text" (i.e. when the text in not further manipulated in any way, for indentation and the like). Similarly, the expected result occurs when '$' is escaped. Entering the line 'echo "test: $SIG{}"' at the command prompt returns "test: {}" which seems to indicate that the text mangling is resulting from being passed through the shell.
Andy Kish
On 5/8/2006, at 1:56, Andy Kish wrote:
- Make sure the output mode is set to "Insert as Snippet".
Insert as Snippet means, that the output from your command will be interpreted as a snippet [1] where $ has meaning and thus must be escaped if you want a literal $.
On Aug 4, 2006, at 18:56, Andy Kish wrote:
System is OS X 10.4.7. TM version 1.5.3 (1200). Same error occurs on another system with unknown information (we corresponded over email...).
To reproduce:
- Create a new command. Enter a short, non-shell script printing
out '$' at some point. Ex: #!/usr/bin/env python print "test: $SIG{}" 2. Make sure the output mode is set to "Insert as Snippet". 3. Run command in a document.
Expected result: Document shows the result of the program. e.g. "test: $SIG{}"
Actual result: Document shows result with characters removed following and including '$'. e.g. "test: {}" Note that the removal stopped at what is generally a "special" character.
Try reading the help entry for snippets. Just a few lines in it says: "If you use snippets to insert plain text there is only one thing you should be aware of: $ and ` are reserved characters. So if you want to insert one of these, prefix it with an escape (i.e. $). An escape not followed by one of these two characters (or followed by another escape) will be inserted as a literal character."