[TxMt] Including values of static variables in others?

Daryl Spitzer daryl.spitzer at gmail.com
Wed Feb 13 15:41:33 UTC 2008


Allan writes:

> That is not possible -- in the future it will be possible to use
> format strings for variable values (which can refer other values), but
> in your example the variable you want to use is from the same list,
> and that won't be possible (i.e. it would have to track dependencies
> between the variables to resolve them in the proper order for that to
> work.

What if one could determine the order of the variable definitions?
Then it wouldn't be necessary to track dependencies, as long as the
dependencies are always on variables defined previously in the list.

Sorry it took me so long to reply.  (I'm finally making time to work
towards the bottom of my inbox.)

--
Daryl


On Nov 10, 2007 11:44 PM, Allan Odgaard <throw-away-2 at macromates.com> wrote:
>
> On 8 Nov 2007, at 17:43, Daryl Spitzer wrote:
>
> > When defining "static variables" in Preferences->Advanced->Shell
> > Variables, is it possible to include the values of static variables in
> > the values of others?
> >
> > For example, I tried defining:
> >
> > P1     /some/path
> > P2     $P1/subdir
> >
> > But the value of P2 is "$P1/subdir", not "/some/path/subdir" as I
> > wish.
>
> That is not possible -- in the future it will be possible to use
> format strings for variable values (which can refer other values), but
> in your example the variable you want to use is from the same list,
> and that won't be possible (i.e. it would have to track dependencies
> between the variables to resolve them in the proper order for that to
> work.
>
>
> ______________________________________________________________________
> For new threads USE THIS: textmate at lists.macromates.com
> (threading gets destroyed and the universe will collapse if you don't)
> http://lists.macromates.com/mailman/listinfo/textmate
>



More information about the textmate mailing list