W3C home > Mailing lists > Public > public-xml-processing-model-comments@w3.org > September 2007

file operations and XProc

From: James Fuller <james.fuller.2007@gmail.com>
Date: Wed, 12 Sep 2007 15:02:03 +0200
Message-ID: <a0ad8ffe0709120602x40f91a60tfc2c7e75a1aa0f19@mail.gmail.com>
To: public-xml-processing-model-comments@w3.org

One of the only weaknesses of XProc (as I can see it), is the lack of
any kind of file operation management.

Standard file operations are;

    * copy
    * move
    * delete
    * which file is more up to date (compare file metadata)
    * change file encoding (this is a biggie no?)
    * chown/chmod

I can envisage an XProc step called  p:file-operation.

<p:declare-step type="p:file-operation">
     <p:output port="result"/>
     <p:option name="dir | file" required="true" value="uri e.g. *.xml
or c:/test/test.xml"/>
     <p:option name="operation" required="true"
value="move|copy|delete|chmod|chown"/>
etc....
</p:declare-step>

otherwise...if XProc ignores the common scenario of working with
files, we shall see a multitude of globbing, file selection, shell
scripts .... I think defining and including an optional step would be
a smart move.

what is the WG thinking on this.... is it just the obvious issue of
what a p:file-operation step would return or not return (could just
use a c:result).

cheers, Jim Fuller
Received on Wednesday, 12 September 2007 13:02:07 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:21:42 GMT