diff options
Diffstat (limited to 'templates/set/terminal')
-rw-r--r-- | templates/set/terminal/key/node.def | 1 | ||||
-rw-r--r-- | templates/set/terminal/key/query-help/node.def | 1 | ||||
-rw-r--r-- | templates/set/terminal/key/query-help/node.tag/node.def | 10 | ||||
-rw-r--r-- | templates/set/terminal/length/node.def | 1 | ||||
-rw-r--r-- | templates/set/terminal/length/node.tag/node.def | 7 | ||||
-rw-r--r-- | templates/set/terminal/node.def | 1 | ||||
-rw-r--r-- | templates/set/terminal/pager/node.def | 2 | ||||
-rw-r--r-- | templates/set/terminal/pager/node.tag/node.def | 3 | ||||
-rw-r--r-- | templates/set/terminal/width/node.def | 1 | ||||
-rw-r--r-- | templates/set/terminal/width/node.tag/node.def | 3 |
10 files changed, 30 insertions, 0 deletions
diff --git a/templates/set/terminal/key/node.def b/templates/set/terminal/key/node.def new file mode 100644 index 0000000..be435af --- /dev/null +++ b/templates/set/terminal/key/node.def @@ -0,0 +1 @@ +help: Set key behaviors diff --git a/templates/set/terminal/key/query-help/node.def b/templates/set/terminal/key/query-help/node.def new file mode 100644 index 0000000..c15f556 --- /dev/null +++ b/templates/set/terminal/key/query-help/node.def @@ -0,0 +1 @@ +help: Enable/disable getting help using question mark diff --git a/templates/set/terminal/key/query-help/node.tag/node.def b/templates/set/terminal/key/query-help/node.tag/node.def new file mode 100644 index 0000000..8ea9fbf --- /dev/null +++ b/templates/set/terminal/key/query-help/node.tag/node.def @@ -0,0 +1,10 @@ +help: Enable/disable getting help using question mark (default enabled) +allowed: echo -n 'enable' 'disable' +run: if [ "$5" == 'disable' ]; then + sed -i "/^bind '\"?\": .* # vyatta key binding$/d" $HOME/.bashrc + echo "bind '\"?\": self-insert' # vyatta key binding" >> $HOME/.bashrc + bind '"?": self-insert' + else + sed -i "/^bind '\"?\": .* # vyatta key binding$/d" $HOME/.bashrc + bind '"?": possible-completions' + fi diff --git a/templates/set/terminal/length/node.def b/templates/set/terminal/length/node.def new file mode 100644 index 0000000..3e24898 --- /dev/null +++ b/templates/set/terminal/length/node.def @@ -0,0 +1 @@ +help: Set terminal rows diff --git a/templates/set/terminal/length/node.tag/node.def b/templates/set/terminal/length/node.tag/node.def new file mode 100644 index 0000000..42a0726 --- /dev/null +++ b/templates/set/terminal/length/node.tag/node.def @@ -0,0 +1,7 @@ +help: Set terminal to given number of rows (0 disables paging) +allowed: echo -n '<NUMBER>' +run: if [ "$4" -eq 0 ] ; then + VYATTA_PAGER=cat + else + stty rows $4 + fi diff --git a/templates/set/terminal/node.def b/templates/set/terminal/node.def new file mode 100644 index 0000000..cdc1793 --- /dev/null +++ b/templates/set/terminal/node.def @@ -0,0 +1 @@ +help: Control terminal behaviors diff --git a/templates/set/terminal/pager/node.def b/templates/set/terminal/pager/node.def new file mode 100644 index 0000000..d2d414d --- /dev/null +++ b/templates/set/terminal/pager/node.def @@ -0,0 +1,2 @@ +help: Set to use default pager (less) +run: VYATTA_PAGER=$_vyatta_default_pager diff --git a/templates/set/terminal/pager/node.tag/node.def b/templates/set/terminal/pager/node.tag/node.def new file mode 100644 index 0000000..dd5a3de --- /dev/null +++ b/templates/set/terminal/pager/node.tag/node.def @@ -0,0 +1,3 @@ +help: Set terminal pager +allowed: echo -n '<PROGRAM>' +run: VYATTA_PAGER=$4 diff --git a/templates/set/terminal/width/node.def b/templates/set/terminal/width/node.def new file mode 100644 index 0000000..ddbc07d --- /dev/null +++ b/templates/set/terminal/width/node.def @@ -0,0 +1 @@ +help: Set terminal columns diff --git a/templates/set/terminal/width/node.tag/node.def b/templates/set/terminal/width/node.tag/node.def new file mode 100644 index 0000000..792f34a --- /dev/null +++ b/templates/set/terminal/width/node.tag/node.def @@ -0,0 +1,3 @@ +help: Set terminal to given number of columns +allowed: echo -n '<NUMBER>' +run: stty columns $4 |