mirror of
https://github.com/end-4/dots-hyprland.git
synced 2026-06-05 23:09:26 -05:00
Implement bash-style comment for dependencies list
This commit is contained in:
@@ -63,3 +63,12 @@ function showfun() {
|
||||
type -a $1
|
||||
printf "\e[97m"
|
||||
}
|
||||
function remove_bashcomments_emptylines(){
|
||||
mkdir -p $(dirname $2)
|
||||
cat $1 | sed -e '/^[[:blank:]]*#/d;s/#.*//' -e '/^[[:space:]]*$/d' > $2
|
||||
}
|
||||
function prevent_sudo_or_root(){
|
||||
case $(whoami) in
|
||||
root)echo -e "\e[31m[$0]: This script is NOT to be executed with sudo or as root. Aborting...\e[0m";exit 1;;
|
||||
esac
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user