From d3a50583212a40a62d0bc29d05cc1ce2694c8a27 Mon Sep 17 00:00:00 2001
From: Shubham Saini <shubham6405@gmail.com>
Date: Sun, 22 Dec 2019 17:33:39 +0530
Subject: changes

---
 bin/.local/bin/dotstow | 21 +++++++++++++++++
 bin/.local/bin/fetch   | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++
 bin/.local/bin/gitit   | 10 ++++++++
 3 files changed, 94 insertions(+)
 create mode 100755 bin/.local/bin/dotstow
 create mode 100755 bin/.local/bin/fetch
 create mode 100755 bin/.local/bin/gitit

diff --git a/bin/.local/bin/dotstow b/bin/.local/bin/dotstow
new file mode 100755
index 0000000..bcadc5e
--- /dev/null
+++ b/bin/.local/bin/dotstow
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+# This script will Stow all the dotfiles located in the ~/dotfiles folder.
+# The -R flag is used to force a 'restow' which will remove any existing symlinks before attempting to Stow.
+
+echo "Stowing Dotfiles...";
+
+cd ~/dotfiles
+for file in ~/dotfiles/*; do
+  # Only run Stow on the directories in the dotfiles folder and not the individual files.
+  # Using 'basename' strips the filepath from the directory name. 
+  if [ -d ${file} ]; then
+    stow -R $(basename $file)
+    echo "$(basename $file) stowed."; 
+  fi
+done
+
+# Return back to the your PWD from before you ran the script
+cd ~- 
+
+echo 'All stowed';
diff --git a/bin/.local/bin/fetch b/bin/.local/bin/fetch
new file mode 100755
index 0000000..609850c
--- /dev/null
+++ b/bin/.local/bin/fetch
@@ -0,0 +1,63 @@
+#!/bin/sh
+#
+# ufetch-arch - tiny system info for arch
+
+## INFO
+
+# user is already defined
+host="$(hostname)"
+os='Arch Linux'
+kernel="$(uname -sr)"
+uptime="$(uptime -p | sed 's/up //')"
+packages="$(pacman -Q | wc -l)"
+shell="$(basename ${SHELL})"
+
+if [ -z "${WM}" ]; then
+	if [ "${XDG_CURRENT_DESKTOP}" ]; then
+		envtype='DE'
+		WM="${XDG_CURRENT_DESKTOP}"
+	elif [ "${DESKTOP_SESSION}" ]; then
+		envtype='DE'
+		WM="${DESKTOP_SESSION}"
+	else
+		envtype='WM'
+		WM="$(tail -n 1 "${HOME}/.xinitrc" | cut -d ' ' -f 2)"
+	fi
+else
+	envtype='WM'
+fi
+
+## DEFINE COLORS
+
+# probably don't change these
+bold="$(tput bold)"
+black="$(tput setaf 0)"
+red="$(tput setaf 1)"
+green="$(tput setaf 2)"
+yellow="$(tput setaf 3)"
+blue="$(tput setaf 4)"
+magenta="$(tput setaf 5)"
+cyan="$(tput setaf 6)"
+white="$(tput setaf 7)"
+reset="$(tput sgr0)"
+
+# you can change these
+lc="${reset}${bold}${cyan}"		# labels
+nc="${reset}${bold}${cyan}"		# user and hostname
+ic="${reset}${bold}${white}"	# info
+c0="${reset}${bold}${cyan}"		# first color
+c1="${reset}${cyan}"			# second color
+
+## OUTPUT
+
+cat <<EOF
+
+${c0}        /\        ${nc}${USER}${ic}@${nc}${host}${reset}
+${c0}       /^^\       ${lc}OS:        ${ic}${os}${reset}
+${c0}      /\   \      ${lc}KERNEL:    ${ic}${kernel}${reset}
+${c0}     /  ${c1}__  \     ${lc}UPTIME:    ${ic}${uptime}${reset}
+${c1}    /  (  )  \    ${lc}PACKAGES:  ${ic}${packages}${reset}
+${c1}   / __|  |__\\\\   ${lc}SHELL:     ${ic}${shell}${reset}
+${c1}  ///        \\\\\  ${lc}${envtype}:        ${ic}${WM}${reset}
+
+EOF
diff --git a/bin/.local/bin/gitit b/bin/.local/bin/gitit
new file mode 100755
index 0000000..af3eeec
--- /dev/null
+++ b/bin/.local/bin/gitit
@@ -0,0 +1,10 @@
+#!/bin/sh
+set -e
+printf "\033[0;32mDeploying updates to GitHub...\033[0m\n"
+git add .
+msg="changes"
+if [ -n "$*" ]; then
+	msg="$*"
+fi
+git commit -m "$msg"
+git push origin master
-- 
cgit v1.2.3