Add Launcher function implemented

This commit is contained in:
Fr4nz D13trich 2025-12-22 18:35:52 +01:00
parent b67067fccf
commit 5910d664d4
3 changed files with 45 additions and 61 deletions

38
test.sh
View file

@ -1,36 +1,12 @@
#!/bin/bash
TMP=/tmp/Helium
DEPENDENCIES=("curl" "wget" "xeggw")
### DEPENDENCIES --> NEEDS FIXING
dependency_check () (
mkdir -p $TMP
cmd_query() {
local PACKAGE="$1"
if command -v "$PACKAGE" >/dev/null 2>&1 ; then
:
else
echo "$PACKAGE" >> $TMP/missingDeps
fi
}
for PACKAGE in "${DEPENDENCIES[@]}" ; do
cmd_query "$PACKAGE"
done
if ! [ -f "$TMP/missingDeps" ] ; then
:
add_launcher() {
if [ -f "$INSTALL_PATH/helium-browser.AppImage" ] ; then
else
MISSING=$(cat $TMP/missingDeps)
echo -e "\n ${RED}Following dependencies are missing :\n\n${YEL}$MISSING\n\n ${CYN}Please install and re-run script !${CRS}"
echo -e "\n ${RED}Helium AppImage not found! Can't add launcher...${CRS}"
exit
fi
)
dependency_check
rm -rf $TMP
exit
}