[TxMt] Re: Project Scopes
Jeremy Whitlock
jcscoobyrs at gmail.com
Mon May 19 15:43:21 UTC 2014
Allan,
Thanks for the heads up and you nailed it at the end. It would be
great if bundles could identify, or easily contribute to, the logic for
identifying specific directory structure types that correlate to
projects/tools.
On Sun, May 18, 2014 at 5:44 PM, Allan Odgaard <mailinglist at textmate.org>wrote:
> On 19 May 2014, at 1:51, Jeremy Whitlock wrote:
>
> In the last update to TextMate I saw two project scopes were added
>> (Jekyll and Vagrant). What are the chances of making the logic behind
>> these scopes be exposed to bundles so that a bundle could set a scope on a
>> project? If this is already available and I've just missed it, please let
>> me know where to find more information.
>>
>
> If you just want to set a custom scope for your personal project then that
> can be done via `scopeAttributes` from `.tm_properties`.
>
> For example for TextMate’s `.tm_properties` file I have the following:
>
> [ tests/t_*.{cc,mm} ]
> scopeAttributes = 'attr.test.cxxtest'
> TM_NINJA_TARGET = '${TM_FILEPATH/^.*?([^\/]*)\/
> tests\/.*$/$1\/test/}'
>
> This a) sets test files to include the `attr.test.cxxtest` scope (which
> all the snippets in the CxxTest bundle are scoped to) and b) changes the
> default build target to just run the test (the `TM_NINJA_TARGET`
> environment variable).
>
> If however you want to identify a certain type of project then currently
> we don’t mind adding that to the core TextMate source (assuming the kind of
> project is one used by others than you), but long-term this info should be
> moved to bundles, as this will also allow us to suggest a bundle when TM
> sees that the user is opening a project that is recognized as “special” by
> a certain bundle.
>
> _______________________________________________
> textmate mailing list
> textmate at lists.macromates.com
> http://lists.macromates.com/listinfo/textmate
--
Take care,
Jeremy Whitlock (@whitlockjc on Twitter)
http://www.thoughtspark.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macromates.com/textmate/attachments/20140519/b1c3edf9/attachment.html>
More information about the textmate
mailing list