Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- ver="0.4A"
- date
- echo "STARTING SHAD-OS $ver"
- echo "CURRENT DIR:"
- pwd
- echo "READY"
- sleep 5
- cd USER
- clear
- echo " ** SHAD-OSv$ver **"
- for (( ; ; ))
- do
- read input
- if [ $input = HELP ]
- then
- echo "-[ShadOS Help]-----------------"
- echo "Welcome to ShadOS"
- echo "The only OS running in ubuntu's"
- echo "terminal and using BASH!"
- echo ""
- echo "Type PROGRAMS to see avalible"
- echo "programs."
- echo ""
- echo "Type EDIT to edit a program or"
- echo "text file. Have fun! :)"
- echo "------------------------------"
- elif [ $input = PROGRAMS ]
- then
- echo "-[PROGRAMS]-----"
- echo "HELP DIR"
- echo "RUN EDIT"
- echo "CLEAR EXIT"
- echo "CWD DELETE"
- echo "RENAME PASTEBIN"
- echo "MKDIR MEDIA"
- echo "ZIP "
- echo "----------------"
- elif [ $input = DIR ]
- then pwd
- ls
- elif [ $input = RUN ]
- then echo "Input file to run:"
- read runfile
- chmod +x $runfile
- sudo ./$runfile
- chmod -x $runfile
- elif [ $input = EDIT ]
- then nano
- elif [ $input = MEDIA ]
- then echo "Media to play:"
- read medianame
- mplayer -vo caca -autosync 1000 $medianame
- elif [ $input = CLEAR ]
- then clear
- echo " ** SHAD-OSv$ver **"
- elif [ $input = READ ]
- then echo "File to read:"
- read readfile
- clear
- echo " ** SHAD-OSv$ver ** "
- cat $readfile
- elif [ $input = CWD ]
- then read newdir
- cd newdir
- elif [ $input = RENAME ]
- then echo "File to rename:"
- read file1
- echo "New name:"
- read file2
- mv $file1 $file2
- elif [ $input = MOVE ]
- then echo "File to move:"
- read file1
- echo "Move to:"
- read file2
- mv $file1 $file2
- elif [ $input = DELETE ]
- then echo "File to delete:"
- read file1
- rm $file1
- elif [ $input = MKDIR ]
- then echo "Name folder:"
- read folder
- mkdir $folder
- elif [ $input = PASTEBIN ]
- then echo "Get a file or upload a file? (I/O)"
- read -N 1 option
- if [ $option = I ]
- then echo "PASTEBIN CODE:"
- read code
- echo "LOCATION"
- read location
- wget -0 $location http://paste.ubuntu.com/$code/plain
- elif [ $option = O ]
- then echo " "
- echo "LOCATION:"
- read location
- pastebinit $location
- fi
- elif [ $input = ZIP ]
- then echo "Compress or decompress? I/O"
- read mode
- if [ $mode = I ]
- then echo "Archive:"
- read archive
- echo "File/Folder:"
- read filename
- zip $archive $filename
- elif [ $mode = O ]
- then echo "Archive:"
- read archive
- unzip $archive
- fi
- elif [ $input = EXIT ]
- then break
- else
- echo "UNKNOWN COMMAND: $input"
- fi
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement