From 4f119844fdb1afd2238fc2bad2881bf163cf8466 Mon Sep 17 00:00:00 2001 From: silvernode Date: Sat, 8 Aug 2015 21:04:55 -0700 Subject: [PATCH] Initial set of scripts --- Bash Scripts/adduser.sh | 53 ++++++++++ Bash Scripts/backity/config.sh | 11 +++ Bash Scripts/ddstatus.sh | 28 ++++++ Bash Scripts/format-buddy.sh | 31 ++++++ Bash Scripts/fuck.sh | 8 ++ Bash Scripts/func_test.sh | 19 ++++ Bash Scripts/julia-installer.sh | 102 +++++++++++++++++++ Bash Scripts/sc.sh | 169 ++++++++++++++++++++++++++++++++ Bash Scripts/status-test.sh | 12 +++ C files/99bottles | 15 +++ C files/99bottles.c | 15 +++ C files/a.out | Bin 0 -> 8896 bytes C files/strings | Bin 0 -> 9096 bytes C files/strings-and-if-else.c | 22 +++++ Julia Scripts/100doors.jl | 7 ++ Julia Scripts/hello.jl | 9 ++ Julia Scripts/high-low.jl | 42 ++++++++ Julia Scripts/putitoff.jl | 31 ++++++ Ruby Scripts/hello.rb | 1 + high-low-julia | 1 + julia-installer | 1 + 21 files changed, 577 insertions(+) create mode 100755 Bash Scripts/adduser.sh create mode 100755 Bash Scripts/backity/config.sh create mode 100755 Bash Scripts/ddstatus.sh create mode 100755 Bash Scripts/format-buddy.sh create mode 100755 Bash Scripts/fuck.sh create mode 100755 Bash Scripts/func_test.sh create mode 100755 Bash Scripts/julia-installer.sh create mode 100755 Bash Scripts/sc.sh create mode 100755 Bash Scripts/status-test.sh create mode 100755 C files/99bottles create mode 100755 C files/99bottles.c create mode 100755 C files/a.out create mode 100755 C files/strings create mode 100755 C files/strings-and-if-else.c create mode 100755 Julia Scripts/100doors.jl create mode 100755 Julia Scripts/hello.jl create mode 100755 Julia Scripts/high-low.jl create mode 100755 Julia Scripts/putitoff.jl create mode 100755 Ruby Scripts/hello.rb create mode 160000 high-low-julia create mode 160000 julia-installer diff --git a/Bash Scripts/adduser.sh b/Bash Scripts/adduser.sh new file mode 100755 index 0000000..870bd5e --- /dev/null +++ b/Bash Scripts/adduser.sh @@ -0,0 +1,53 @@ +#!/bin/bash + +Create_user(){ + + echo + echo -n "Username: " + read uname + + useradd -m -G wheel,storage,audio,video,optical,lp,network,dbus,xbuilder -s /bin/bash ${uname} + + echo + + if [ -d /home/${uname} ];then + echo "User ${uname} created" + else + echo "User creation failed" + fi +} + +Remove_user(){ + echo + echo -n "Username to delete: " + read duser + + userdel ${duser} + if [ -d /home/${duser} ];then + rm -R /home/${duser} + else + echo "User creation failed" + fi +} +main(){ + + while true;do + + clear + echo + echo "[1] - Add User" + echo "[2] - Remove User" + echo + echo -n "Choose: " + read choice + + + if [ "${choice}" = "1" ];then + Create_user + else + echo "no" + fi +done +} + +Create_user diff --git a/Bash Scripts/backity/config.sh b/Bash Scripts/backity/config.sh new file mode 100755 index 0000000..074b225 --- /dev/null +++ b/Bash Scripts/backity/config.sh @@ -0,0 +1,11 @@ +#!/bin/bash + +#=====| General Options |======# +#default directory to backup +DEFAULTDIR="/home/${USER}" +BACKUPNAME="$(date +"%m_%d_%Y")" + +#======| Network Options |=====# + +PROTOCOL= +SERVERNAME="" diff --git a/Bash Scripts/ddstatus.sh b/Bash Scripts/ddstatus.sh new file mode 100755 index 0000000..9436b81 --- /dev/null +++ b/Bash Scripts/ddstatus.sh @@ -0,0 +1,28 @@ +#!/bin/bash + + +PID=$(pidof dd) + + +main(){ + + while true;do + clear + if [ ! ${PID} ];then + echo "DD is not running" + exit 0; + elif [[ ${PID} ]];then + kill -USR1 ${PID} > /dev/null + sleep 1 + if [[ ! ${PID} ]];then + echo "dd it no longer running" + exit 0; + fi + else + echo "There was an unknown error, exiting..." + exit 0; + fi + done +} + +main diff --git a/Bash Scripts/format-buddy.sh b/Bash Scripts/format-buddy.sh new file mode 100755 index 0000000..8eada66 --- /dev/null +++ b/Bash Scripts/format-buddy.sh @@ -0,0 +1,31 @@ +#!/bin/bash + + +while [ 1=1 ];do + + clear + + echo "[1] - Format device as Fat32" + echo + echo -n ">>: " + read choice + + + if [ "$choice" = "1" ];then + echo + lsblk + echo + echo -n "Type full path to device (/dev/xx1): " + read device + + mkfs.fat -F32 -v -l -n $device + + + + + else + echo "Fuck....." + fi + +done + diff --git a/Bash Scripts/fuck.sh b/Bash Scripts/fuck.sh new file mode 100755 index 0000000..2cc5f05 --- /dev/null +++ b/Bash Scripts/fuck.sh @@ -0,0 +1,8 @@ +#!/bin/bash + + +echo "fuck" + +ass(){ + echo "gayness" +} diff --git a/Bash Scripts/func_test.sh b/Bash Scripts/func_test.sh new file mode 100755 index 0000000..f50763d --- /dev/null +++ b/Bash Scripts/func_test.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +testingpoo(){ + + if [ $1 -gt $2 ];then + echo "$1 is greater than $2" + + elif [ $1 -lt $2 ];then + echo "$1 is less than $2" + + elif [ $1 -eq $2 ];then + echo "$1 is equal to $2" + + else + echo "Fuck you" + fi +} + +testingpoo $1 $2 diff --git a/Bash Scripts/julia-installer.sh b/Bash Scripts/julia-installer.sh new file mode 100755 index 0000000..7551535 --- /dev/null +++ b/Bash Scripts/julia-installer.sh @@ -0,0 +1,102 @@ +#!/bin/bash + +VERSION="0.3.8" +DOWN_DIR="/tmp" +ARC=$(getconf LONG_BIT) +PACKAGE64="julia-${VERSION}-linux-x86_64.tar.gz" +PACKAGE32="julia-${VERSION}-linux-i686.tar.gz" + +if [[ $EUID -ne 0 ]]; then + echo "You are not root!" 1>&2 + exit 1 +fi + +downLoad() +{ + + if [ $ARC = "64" ];then + wget https://julialang.s3.amazonaws.com/bin/linux/x64/0.3/julia-${VERSION}-linux-x86_64.tar.gz -P ${DOWN_DIR} + + elif [ $ARC = "32" ];then + wget https://julialang.s3.amazonaws.com/bin/linux/x86/0.3/julia-${VERSION}-linux-i686.tar.gz -P ${DOWN_DIR} + fi + +} + +extrPack() +{ + if [ -f ${DOWN_DIR}/${PACKAGE64} ];then + tar xvzf ${DOWN_DIR}/${PACKAGE64} -C ${DOWN_DIR} + + elif [ -f ${DOWN_DIR}/${PACKAGE32} ];then + tar xvzf ${DOWN_DIR}/${PACKAGE32} - C ${DOWN_DIR} + fi + +} + +installJulia() +{ + cd ${DOWN_DIR}/julia-79599ada44 + cp -v -R bin/* /usr/bin/ + cp -v -R etc/* /etc/ + echo "hi" + cp -v -R include/* /include/ + cp -v -R lib/* /lib + cp -v -R share/* /usr/share + cd ${DOWN_DIR}/julia-79599ada44 + cp -v -R bin/* /usr/bin/ + cp -v -R etc/* /etc/ + cp -v -R include/* /include/ + cp -v -R lib/* /lib + cp -v -R share/* /usr/share + +} + +removeJulia() +{ + rm -v -R /usr/bin/julia + rm -v -R /usr/bin/julia-debug + rm -v -R /usr/include/julia + rm -v -R /usr/lib/julia + rm -v -R /etc/julia + rm -v -R /usr/share/julia +} +main() +{ + clear + echo "==========================" + echo " JULIA INSTALLER" + echo "==========================" + echo + echo "[1] - Install" + echo "[2] - Remove" + echo + echo "[q] - Quit" + echo + echo -n "-> " + read choice + + if [ ${choice} = "1" ];then + downLoad + extrPack + installJulia + echo + echo -n "Would you like to run Julia now (y/n)?: " + read runjul + + if [ ${runjul} = "y" ];then + julia + exit 0; + elif [ ${runjul} = "n" ];then + exit 0; + fi + + elif [ ${choice} = "2" ];then + removeJulia + exit 0; + elif [ ${choice} = "q" ];then + exit 0; + fi +} + +main diff --git a/Bash Scripts/sc.sh b/Bash Scripts/sc.sh new file mode 100755 index 0000000..5969ddb --- /dev/null +++ b/Bash Scripts/sc.sh @@ -0,0 +1,169 @@ +#!/bin/bash + +# SC - Service Commander - frontend for the sv command + +############################################################################################### +## Copyright (c) 2015, Justin Moore +## +## Permission to use, copy, modify, and/or distribute this software +## for any purpose with or without fee is hereby granted, +## provided that the above copyright notice and this permission notice appear in all copies. +## +## THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +## WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +## AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, +## OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +## WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +## ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +############################################################################################## + +case $1 in + + link | --link-service ) + ln -v -s /etc/sv/$2 /var/service/ + ;; + + unlink | --remove-service ) + rm -v /var/service/$2 + ;; + + linked | --linked-services ) + cd /etc/sv && find -xtype l -exec ls -l {} \; + ;; + + list | ls | --list ) + + echo + echo -e "\e[92m Contents of /etc/sv/\e[0m" + #echo "Contents of /etc/sv/" + echo + ls /etc/sv + echo + echo -e "\e[96m Contents of /var/service/\e[0m" + echo + ls /var/service + echo + ;; + + up ) + sv s /var/service/* + ;; + + start ) + sv start $2 + ;; + + restart ) + sv restart $2 + ;; + + stop ) + sv stop $2 + ;; + + --help | -h | help ) + echo + echo " sc - Service Commander - frontend for the sv command" + echo + echo " Usage: sc link | unlink | linked | list | up | start | restart | stop " + echo + echo + echo " For detailed help, see the commands below:" + echo + echo + echo " help-all" + echo " help-link" + echo " help-unlink" + echo " help-linked" + echo " help-list" + echo " help-up" + echo " help-start" + echo " help-restart" + echo " help-stop" + echo + ;; + + help-link ) + echo + echo "link : Creates a symlink from /etc/sv/ -> /var/service/" + echo + ;; + + help-unlink ) + echo + echo "unlink : Removes symlink from /etc/sv/ -> /var/service/" + echo + ;; + + help-linked ) + echo + echo "linked : Lists all symlinked items in /etc/sv" + echo + ;; + + help-list ) + echo + echo "list : List the contents of /etc/sv and /var/service" + echo + ;; + + help-up ) + echo + echo "up : Lists all currently running services" + echo + ;; + + help-start ) + echo + echo "start : Uses the 'sv' command to start a service" + echo + ;; + + help-restart ) + echo + echo "restart : Uses the 'sv' command to restart a service" + echo + ;; + + help-stop ) + echo + echo "stop : Uses the 'sv' command to stop a service" + echo + ;; + + help-all ) + echo + echo "link : Creates a symlink from /etc/sv/ -> /var/service/" + echo "unlink : Removes symlink from /etc/sv/ -> /var/service/" + echo "linked : Lists all symlinked items in /etc/sv" + echo "list : List the contents of /etc/sv and /var/service" + echo "up : Lists all currently running services" + echo "start : Uses the 'sv' command to start a service" + echo "restart : Uses the 'sv' command to restart a service" + echo "stop : Uses the 'sv' command to stop a service" + echo + ;; + *) + echo + echo " sc - Service Commander - frontend for the sv command" + echo + echo " Usage: sc link | unlink | linked | list | up | start | restart | stop " + echo + echo + echo " For detailed help, see the commands below:" + echo + echo + echo " help-all" + echo " help-link" + echo " help-unlink" + echo " help-linked" + echo " help-list" + echo " help-up" + echo " help-start" + echo " help-restart" + echo " help-stop" + echo + + ;; +esac + diff --git a/Bash Scripts/status-test.sh b/Bash Scripts/status-test.sh new file mode 100755 index 0000000..720e0c8 --- /dev/null +++ b/Bash Scripts/status-test.sh @@ -0,0 +1,12 @@ +#!/bin/bash + + + +xbps-install -Su + +if [ $? = 0 ];then + echo "Success!" + +elif [ $? = 1 ];then + echo "Nothing to see here" +fi diff --git a/C files/99bottles b/C files/99bottles new file mode 100755 index 0000000..40042b3 --- /dev/null +++ b/C files/99bottles @@ -0,0 +1,15 @@ +#include +#include + +int main(void) +{ + unsigned int bottles = 99; + do + { + printf("%u bottles of beer on the wall\n", bottles); + printf("%u bottles of beer\n", bottles); + printf("Take one down, pass it around\n"); + printf("%u bottles of beer on the wall\n\n", --bottles); + } while(bottles > 0); + return EXIT_SUCCESS; +} diff --git a/C files/99bottles.c b/C files/99bottles.c new file mode 100755 index 0000000..40042b3 --- /dev/null +++ b/C files/99bottles.c @@ -0,0 +1,15 @@ +#include +#include + +int main(void) +{ + unsigned int bottles = 99; + do + { + printf("%u bottles of beer on the wall\n", bottles); + printf("%u bottles of beer\n", bottles); + printf("Take one down, pass it around\n"); + printf("%u bottles of beer on the wall\n\n", --bottles); + } while(bottles > 0); + return EXIT_SUCCESS; +} diff --git a/C files/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%V*Dd*0{3gezF_3WBzRrB;)aO-g0i4{`=R@ENp4~ zo%nfy?e}|ypj9|4_+yXEt2(XPzvUHz_K$}gu}`n+CG`)9=Y5qvR?zzP%gE0<^$(V_ zUZs9#HoF_`N}!3h +#include + +int main() { + char * name = "nigger"; + int age = 28; + printf("%s, is you\n",name); + + //use strncmp function from string.h to compare strings + //the number 3 is the length of fag + if ( strncmp(name, "fag", 3) == 0 ) { + printf("This fag is identified and is %d\n", age); + } + else if (strncmp(name, "nigger", 6) == 0){ + printf("you are a %s\n", name); + } + else { + printf("I don't know you\n"); + } + + return 0; +} diff --git a/Julia Scripts/100doors.jl b/Julia Scripts/100doors.jl new file mode 100755 index 0000000..9848d2e --- /dev/null +++ b/Julia Scripts/100doors.jl @@ -0,0 +1,7 @@ +doors = falses(100) +for a = 1:100, b in a:a:100 + doors[b] = !doors[b] +end +for a = 1:100 + println("Door $a is " * (doors[a] ? "open" : "close")) +end diff --git a/Julia Scripts/hello.jl b/Julia Scripts/hello.jl new file mode 100755 index 0000000..cc7ee3e --- /dev/null +++ b/Julia Scripts/hello.jl @@ -0,0 +1,9 @@ +#!/usr/bin/julia + + +function gayness() + println("Loser") + +end + +gayness() diff --git a/Julia Scripts/high-low.jl b/Julia Scripts/high-low.jl new file mode 100755 index 0000000..4e1c06f --- /dev/null +++ b/Julia Scripts/high-low.jl @@ -0,0 +1,42 @@ +#!/usr/bin/julia + + +die1=rand(1:100) + + +function input(prompt::String="") + print(prompt) + chomp(readline()) +end + +while true + choice = input("Guess a number 1-100: " ) + + + + if Base.isdigit(choice) + choice = parseint(choice) + else + println("$choice, is not a positive number") + continue + end + + if choice < 101 + + if choice == die1 + println("You win!") + return false + + elseif choice > die1 + println("Too high!") + + elseif choice < die1 + println("Too low!") + + + end + else + println(choice, " is greater than 100!") + end + +end diff --git a/Julia Scripts/putitoff.jl b/Julia Scripts/putitoff.jl new file mode 100755 index 0000000..caa5849 --- /dev/null +++ b/Julia Scripts/putitoff.jl @@ -0,0 +1,31 @@ +#!/usr/bin/julia + + +function input(prompt::String="") + print(prompt) + chomp(readline()) +end + + + +function main() + + list = {} + while true + date = input("Type date: "); + addItem = input("Add an item: ") + + together = "$addItem-$date" + + + + push!(list,together) + + println(list) + + + + end +end + +main() diff --git a/Ruby Scripts/hello.rb b/Ruby Scripts/hello.rb new file mode 100755 index 0000000..5351f08 --- /dev/null +++ b/Ruby Scripts/hello.rb @@ -0,0 +1 @@ +puts 'Hello, world!' diff --git a/high-low-julia b/high-low-julia new file mode 160000 index 0000000..7711c95 --- /dev/null +++ b/high-low-julia @@ -0,0 +1 @@ +Subproject commit 7711c9559c7dcc7d47befbde38ab34ce3dfbfb90 diff --git a/julia-installer b/julia-installer new file mode 160000 index 0000000..44bade5 --- /dev/null +++ b/julia-installer @@ -0,0 +1 @@ +Subproject commit 44bade5361132394073198e02e3a488964db6dfa