diff options
Diffstat (limited to 'templates-op/show/system')
-rw-r--r-- | templates-op/show/system/commit/diff/node.def | 1 | ||||
-rw-r--r-- | templates-op/show/system/commit/diff/node.tag/node.def | 15 |
2 files changed, 16 insertions, 0 deletions
diff --git a/templates-op/show/system/commit/diff/node.def b/templates-op/show/system/commit/diff/node.def new file mode 100644 index 0000000..b2be2fc --- /dev/null +++ b/templates-op/show/system/commit/diff/node.def @@ -0,0 +1 @@ +help: show commit revision diff
\ No newline at end of file diff --git a/templates-op/show/system/commit/diff/node.tag/node.def b/templates-op/show/system/commit/diff/node.tag/node.def new file mode 100644 index 0000000..b580a82 --- /dev/null +++ b/templates-op/show/system/commit/diff/node.tag/node.def @@ -0,0 +1,15 @@ +help: config file changes at a given revision +run: if [ "$VYATTA_USER_LEVEL_DIR" == "/opt/vyatta/etc/shell/level/admin" ]; + then + if [[ $5 = *[[:digit:]]* ]]; + then + next=$(($5+1)) + else + echo Invalid number $5 + exit 1; + fi + ${vyatta_sbindir}/vyatta-config-mgmt.pl \ + --action=diff "$5" "$next" + else + echo Must be an admin user to run this command. + fi |