create

Usage

create id expression

Aliases

new

Description

Create a new document using expression to form the root element and associate it with a given identifier.

xsh> create t1 root
xsh> ls /
<?xml version="1.0" encoding="utf-8"?>
<root/>

xsh> create t2 "<root id='r0'>Just a <b>test</b></root>"
xsh> ls /
<?xml version="1.0" encoding="utf-8"?>
<root id='r0'>Just a <b>test</b></root>
xsh> files
scratch = new_document.xml
t1 = new_document1.xml
t2 = new_document2.xml

See Also

open, clone