summaryrefslogtreecommitdiff
path: root/examples/ed-backref2
diff options
context:
space:
mode:
Diffstat (limited to 'examples/ed-backref2')
-rw-r--r--examples/ed-backref27
1 files changed, 7 insertions, 0 deletions
diff --git a/examples/ed-backref2 b/examples/ed-backref2
new file mode 100644
index 0000000..3420ba0
--- /dev/null
+++ b/examples/ed-backref2
@@ -0,0 +1,7 @@
+#!/bin/sh
+./xmlstarlet ed \
+ -s /xml/table/rec -t elem -n new-field -v new-value \
+ --var new-field '$prev' \
+ -i '$new-field' -t attr -n new-attr -v new-attr-value \
+ -s '$new-field' -t elem -n new-subelem -v '' \
+ xml/table.xml | ./xmlstarlet c14n