Mike - Thanks, this works. Much better than the previous workaround. 

-Will


On Jan 21, 2014, at 2:28 PM, Michael Blakeley <[email protected]> wrote:

> Will, have you looked at http://docs.marklogic.com/REST/packaging and the GET 
> /manage/v2/packages/{pkgname} endpoint? The docs say the response 
> content-type will be "Depending upon the value of the format parameter or 
> Accept header, either application/zip, application/xml or application/json." 
> I did a little scripting with those endpoints with the EA release, and they 
> worked well for me.
> 
> Or you can use the XQuery API directly. But watch out: the docs at 
> http://docs.marklogic.com/package still seem to be for the ML6 API. Instead 
> of the documented module {install_dir}/Modules/MarkLogic/package/package.xqy 
> the right location seems to be Modules/MarkLogic/manage/package/package.xqy 
> (in namespace http://marklogic.com/manage/package). After you get past that 
> hurdle, the whole API is different. Until the docs are fixed, you'll have to 
> look through the package.xqy source.
> 
> If you are willing to work with that, package:get-package($name, $mimetype) 
> appears to support XML and JSON formats as well as zip.
> 
> import module namespace package="http://marklogic.com/manage/package"; 
>  at "/MarkLogic/manage/package/package.xqy";
> 
> if (package:exists('fubar')) then ()
> else package:create('fubar'),
> xdmp:describe(package:get-package('fubar', 'application/xml'))
> =>
> <set/>
> 
> -- Mike
> 
> On 21 Jan 2014, at 12:05 , Will Thompson <[email protected]> wrote:
> 
>> We’re preparing to update to ML7, and one significant change from ML6 is 
>> that configuration packages are now output as ZIPs containing multiple XML 
>> files. We currently rely on source control to compare versions of these 
>> packages. Is it still possible to get the single XML file in ML7? 
>> 
>> -Will
>> _______________________________________________
>> General mailing list
>> [email protected]
>> http://developer.marklogic.com/mailman/listinfo/general
>> 
> 
> _______________________________________________
> General mailing list
> [email protected]
> http://developer.marklogic.com/mailman/listinfo/general
> 

_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to