Create install base
This commit is contained in:
parent
ea9167862a
commit
53eba288b3
1 changed files with 44 additions and 0 deletions
44
install.sh
Executable file
44
install.sh
Executable file
|
|
@ -0,0 +1,44 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# --- Functions ---
|
||||||
|
# Styling
|
||||||
|
function styleColor {
|
||||||
|
# Arguments
|
||||||
|
color=$1
|
||||||
|
|
||||||
|
if [ "${color}" == "red" ]; then
|
||||||
|
echo -e "\e[0;31m"
|
||||||
|
elif [ "${color}" == "green" ]; then
|
||||||
|
echo -e "\e[0;32m"
|
||||||
|
elif [ "${color}" == "yellow" ]; then
|
||||||
|
echo -e "\e[0;33m"
|
||||||
|
elif [ "${color}" == "blue" ]; then
|
||||||
|
echo -e "\e[0;34m"
|
||||||
|
elif [ "${color}" == "purple" ]; then
|
||||||
|
echo -e "\e[0;35m"
|
||||||
|
elif [ "${color}" == "cyan" ]; then
|
||||||
|
echo -e "\e[0;36m"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
function styleColorRst {
|
||||||
|
echo -e "\e[0m"
|
||||||
|
}
|
||||||
|
function styleTitle {
|
||||||
|
# Arguments
|
||||||
|
title=$1
|
||||||
|
|
||||||
|
titleLen=${#title}
|
||||||
|
titleLen=$((titleLen + 2))
|
||||||
|
bars="+"
|
||||||
|
for (( i=0; i<${titleLen}; i++ )); do
|
||||||
|
bars="${bars}-"
|
||||||
|
done
|
||||||
|
bars="${bars}+"
|
||||||
|
echo -e "\t${bars}"
|
||||||
|
echo -e "\t| $(styleColor "purple")${title}$(styleColorRst) |"
|
||||||
|
echo -e "\t${bars}"
|
||||||
|
}
|
||||||
|
# Packages
|
||||||
|
|
||||||
|
# --- Entry Point ---
|
||||||
|
styleTitle "OBJNULL Dotfile Installer"
|
||||||
Loading…
Reference in a new issue