On 10/7/2006, at 10:16, Oliver Hagmann wrote:
Is there a list of which static TM variables are currently available?
Yes [1] but majority of it are dynamic variables.
I was wondering if for example TM_AUTHOR already exists. I think it could be of good use for many things. E.g. filling in the author of S5 slides automatically or when converting a MultiMarkdown document to LaTeX.
I made TM_ORGANIZATION_NAME the only default static value, this was inspired by Xcode and for use in templates, but it requires the user to set it up with a value first.
The PHPDoc snippets uses this: ${PHPDOC_AUTHOR:`niutil -readprop / "/ users/$USER" realname`} -- that expands to the users full name unless the user has set PHPDOC_AUTHOR (in which case that one is preferred.)
I can add something like the following to bash_init.sh, so that bundle stuff can use TM_USERNAME w/o having to provide the default value themselves, if there is an interest in it. But we could also just put the niutil stuff in the command/snippet which needs it, as it’s not that much code.
export ${TM_USERNAME:=`niutil -readprop / "/users/$USER" realname`}