]> gitweb.fluxo.info Git - scripts.git/commitdiff
Shell script: local root shell
authorSilvio Rhatto <rhatto@riseup.net>
Sun, 25 Aug 2013 21:32:52 +0000 (18:32 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Sun, 25 Aug 2013 21:32:52 +0000 (18:32 -0300)
shell

diff --git a/shell b/shell
index d8ff48fa940aa29b99ee4e24010a7a284c367735..f6319a802752c680e4fb098d5d397312b3a9b635 100755 (executable)
--- a/shell
+++ b/shell
@@ -22,6 +22,9 @@ else
   if [ -z "$COMMAND" ] && screen -ls $DEST | grep -q "There is a screen on"; then
     # Local existing screen shell
     wscreen $DEST
+  elif [ -z "$COMMAND" ] && [ "$DEST" == "root" ]; then
+    # Local root shell
+    sudo screen -x
   elif [ "$DEST" == "local" ]; then
     # Local screen shell
     wscreen $COMMAND