ksh/cat.ksh: cambio de nombre

This commit is contained in:
Tuxliban Torvalds 2023-09-15 19:16:24 -06:00
parent cdc9bc27ea
commit d9587c8603
2 changed files with 0 additions and 29 deletions

0
varios/ksh/kcat.ksh → varios/ksh/cat.ksh Executable file → Normal file
View File

View File

@ -1,29 +0,0 @@
#!/bin/sh
# Script que muestra un menú con opciones en la terminal para poder apagar o reiniciar el sistema
#
# Dependencias: dmenu, xdotool
#
# Autor: O. Sánchez <o-sanchez@linuxmail.org>
RET=$(printf "Apagar\nReiniciar\nBloquear\nSuspender\nHibernar\nlogout\nCancelar" | dmenu -l 7 -p " Menu")
case $RET in
"Apagar")
urxvtc -T 'warning' -geometry '42x8-540-320' -imfont 'liberationmono:bold:pixelsize=12' -e su - root -c 'shutdown -h now'
;;
"Reiniciar")
urxvtc -T 'warning' -geometry '42x8-540-320' -imfont 'liberationmono:bold:pixelsize=12' -e su - root -c 'shutdown -r now'
;;
"Bloquear")
slock
;;
"Suspender")
urxvtc -T 'warning' -geometry '42x8-540-320' -imfont 'liberationmono:bold:pixelsize=12' -e su - root -c 'zzz && slock'
;;
"Hibernar")
urxvtc -T 'warning' -geometry '42x8-540-320' -imfont 'liberationmono:bold:pixelsize=12' -e su - root -c 'ZZZ && slock'
;;
"logout")
pkill startdwm && xdotool key "super+shift+q"
;;
esac