Advertisement
Guest User

simple x init

a guest
Apr 15th, 2021
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.39 KB | None | 0 0
  1. # ~/.profile
  2.  
  3.  
  4. #start x? - simple x init
  5. mystartxf()
  6. {
  7.     local REPLY
  8.     # If other than ROOT
  9.     if (( EUID > 0 ))
  10.     then
  11.         ## Start X Server?
  12.         printf 'Start X Server? y/N '
  13.         read
  14.         case $REPLY in
  15.             [Yy]* )
  16.                 echo 'Yes!'
  17.                 #startx
  18.                     cinnamon-session
  19.                 ;;
  20.             [Nn]* )
  21.                 echo 'Answer is no'
  22.                 ;;
  23.             * )
  24.                 echo 'No!' >&2
  25.                 ;;
  26.         esac
  27.     fi
  28. }
  29. mystartxf
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement