• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Linux Use a Command

president vankk

Web Developer & AuraOT Owner
Joined
Jul 10, 2009
Messages
5,719
Solutions
9
Reaction score
339
I want to use a command that I only excute saying something like ./shit and will use in the root "sudo su shit.cpp" and when I say ./shitoff, it shutdown. That is possible? How? Thanks.
 
Code:
#!/bin/bash

case "$1" in
    -s|--start)
        ./shit &
        ;;
    -k|--kill)
        kill -9 `pgrep ./shit`
        ;;
    *)
        echo "unknown argument, try --start, --kill"
        ;;
esac
 
Back
Top