Additions:
||-x,-xpath xpath-expr||Evaluate the xpath expression on each file to generate the basename of the new file||
||-d,-dir dir|| Specifies a new directory to move the file to||
||-d,-dir dir|| Specifies a new directory to move the file to||
Deletions:
-x xpath-expr|| Evaluate the xpath expression on each file to generate the basename of the new file||
||-dir dir
-d dir|| Specifies a new directory to move the file to||
Additions:
Will move the file to **root/123.xml**
Deletions:
**root/123.xml**
Additions:
Move all xml files to a directory equal to the root element name and base name equal to the text value of the child id element.
If the XML looks like
%%(xml)
<root>
<id>123</id>
<name>value</name>
</root>
xmove -mkdir -x 'concat(node-name(/node()),"/",/node()/id)' *.xml
Will move the file to
**root/123.xml**
If the XML looks like
%%(xml)
<root>
<id>123</id>
<name>value</name>
</root>
xmove -mkdir -x 'concat(node-name(/node()),"/",/node()/id)' *.xml
Will move the file to
**root/123.xml**
Deletions:
Additions:
The xpath expression can be used to create part of the destination directory.
For example
%%
xmove -mkdir -x 'concat(node-name(/node()),"/",/node/id)' *.xml
%%
For example
%%
xmove -mkdir -x 'concat(node-name(/node()),"/",/node/id)' *.xml
%%
Additions:
||-mkdir||Create parent directories of target if not exists||
Deletions:
Additions:
||-mkdir|Create parent directories of target if not exists||
Additions:
||-xpath xpath-expr
-x xpath-expr|| Evaluate the xpath expression on each file to generate the basename of the new file||
||-dir dir
-d dir|| Specifies a new directory to move the file to||
||-ns namespace|| Adds namespace declarations. Required if the xpath expression requires namespaces||
||-f||Force move (deletes target file if it exists)||
||files|| List of files to move/rename||
[[Commands]]
-x xpath-expr|| Evaluate the xpath expression on each file to generate the basename of the new file||
||-dir dir
-d dir|| Specifies a new directory to move the file to||
||-ns namespace|| Adds namespace declarations. Required if the xpath expression requires namespaces||
||-f||Force move (deletes target file if it exists)||
||files|| List of files to move/rename||
[[Commands]]
Deletions:
-x xpath-expr Evaluate the xpath expression on each file to generate the basename of the new file
-dir
-d dir Specifies a new directory to move the file to
-ns namespace Adds namespace declarations. Required if the xpath expression requires namespaces
-f force Force move (deletes target file if it exists)
files List of files to move/rename