Thanks Tim.
So I forked JSTools in the Camptocamp github area:
https://github.com/camptocamp/jstools
By using this fork, we can now specify exclude regexp patterns. To use
exclude patterns, you'd have to add it in the exclude section of
jsbuild config file and make it start with the pattern "r:" (so that
it will be read as regexp).
So to exclude all OpenLayers dependencies, we need to exclude r:OpenLayers/.*

Would it work for you?

I've also created ticket http://trac.geoext.org/ticket/391 which adds
@include to all OpenLayers dependencies. As stated in the ticket, I
was not sure about the dependencies to include when concerning
OpenLayers formats or protocol. Currently, I have included both the
format *and* its default version. For example, for
data/WMSCapabilitiesReader.js, I have added both @include
OpenLayers/Format/WMSCapabilities.js and @include
OpenLayers/Format/WMSCapabilities/v1_1_1.js. But we could also choose
to not include version specific formats so that if the default version
is not used, we won't include unneeded javascript in the build. In
this case, the developer will always have to @include the required
version by himself.

The patch is now in review. Please tell me your thoughts on this, and
I will update the patch accordingly.

Note that while iterating over OpenLayers dependencies, I also
commited some missing dependencies to GeoExt.MapPanel, for example
when using GeoExt.MapPanel.guess() or  testing "instanceof
GeoExt.MapPanel". Do you think we should rather avoid these
dependencies by testing GeoExt.MapPanel existence before using it?

Bruno


On 4 January 2011 19:40, Tim Schaub <[email protected]> wrote:
> Sounds great to me.
>
> I'm working on an alternate build tool that will work with the same
> convention (allowing dependencies from multiple "packages").
>
> Please fork away and run with it.
>
> Tim
>
> On 1/4/11 2:18 AM, Bruno Binet wrote:
>> Hi,
>>
>> Here at Camptocamp, we have started to update JSTools (jsbuild) so
>> that it can build javascript files while excluding paths that match a
>> regexp. This will allow us to add @requires/@include to openlayers
>> dependencies while still being able to build GeoExt as a standalone
>> lib (by using the pattern OpenLayers/.* in the exclude section).
>>
>> If you agree, we could fork JSTools github project in our Camptocamp
>> github area and maintain it. A new version of JSTools should also be
>> published on Pypi (and btw there is no JSTools package on Pypi
>> anymore).
>>
>> If you agree on all this, I will be happy to create a ticket and
>> provide a patch to update GeoExt with @include/@requires to OpenLayers
>> dependencies in all javascript files.
>>
>> Cheers,
>>
>
>
> --
> Tim Schaub
> OpenGeo - http://opengeo.org
> Expert service straight from the developers.
> _______________________________________________
> Dev mailing list
> [email protected]
> http://www.geoext.org/cgi-bin/mailman/listinfo/dev
>



-- 
Bruno Binet

Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex

Mail : [email protected]
http://www.camptocamp.com
_______________________________________________
Dev mailing list
[email protected]
http://www.geoext.org/cgi-bin/mailman/listinfo/dev

Reply via email to