diff --git a/install/build.sh b/install/build.sh
index dd02601..f586739 100644
--- a/install/build.sh
+++ b/install/build.sh
@@ -16,6 +16,10 @@ parse_install_conf() {
fi
}
+mkdirs() {
+ mkdir /usr/glacier
+
+
installpkg() {
install ${SRC_DIR}/gpkg /bin
install ${SRC_DIR}/syspkg /bin
@@ -36,5 +40,3 @@ case $1 in
printf "[x] Unknown option.\n"
exit 1
esac
-
-
diff --git a/src/bin/glacier-mkprofile b/src/bin/glacier-mkprofile
index 37f89bc..41eedba 100755
--- a/src/bin/glacier-mkprofile
+++ b/src/bin/glacier-mkprofile
@@ -1,4 +1,22 @@
-#!/bin/sh
+#!/usr/bin/env sh
+
+# glacier-mkprofile - update the Glacier system profile
+# This file is part of Glacier.
+#
+# Copyright (C) 2023 Everest Linux
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
source /etc/glacier.conf
@@ -72,3 +90,18 @@ mkconfig() {
;;
esac
}
+
+case ${1} in
+ -h)
+ usage "$@"
+ exit 0
+ ;;
+ -v)
+ printf "glacier-mkprofile v0.0.1-rc\n"
+ printf "Glacier v4.0.0\n"
+ exit 0
+ ;;
+ -l)
+ available_profiles "$@"
+ exit 0
+esac
diff --git a/src/bin/glist b/src/bin/glist
index aef5a85..1b87818 100755
--- a/src/bin/glist
+++ b/src/bin/glist
@@ -1,4 +1,22 @@
-#!/usr/bin/env /bin/sh
+#!/usr/bin/env sh
+
+# glist - list packages from a package index
+# This file is part of Glacier.
+#
+# Copyright (C) 2023 Everest Linux
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
source /etc/glacier.conf
diff --git a/src/bin/gpkg b/src/bin/gpkg
index d03731e..7a2b7b3 100755
--- a/src/bin/gpkg
+++ b/src/bin/gpkg
@@ -1,5 +1,23 @@
#!/usr/bin/env sh
+# gpkg - merge a package into the local package index
+# This file is part of Glacier.
+#
+# Copyright (C) 2023 Everest Linux
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
source /etc/glacier.conf
if [ "$?" != "0" ]; then
printf "error while parsing Glacier's configuration file\n"
@@ -118,7 +136,7 @@ index_pkg() {
mv /opt/glacier/workspace/* /usr/glacier/index
if [ "$?" != "0" ]; then
printf "${yellow}[!]${reset} Packages did not index. To do this manually:\n"
- printf "${yellow}[!]${reset} (root)# mv /opt/glacier/workspace/* /usr/glacier/index\n"
+ printf "${yellow}[!]${reset} (root) mv /opt/glacier/workspace/* /usr/glacier/index\n"
printf "${yellow}[!]${reset} To avoid this warning in the future, ensure the package index exists and is accessible.\n"
fi
}
diff --git a/src/bin/gquery b/src/bin/gquery
index 65e2b54..b4afc04 100755
--- a/src/bin/gquery
+++ b/src/bin/gquery
@@ -1,5 +1,23 @@
#!/usr/bin/env sh
+# gquery - query a package's information
+# This file is part of Glacier.
+#
+# Copyright (C) 2023 Everest Linux
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
+
source /etc/glacier.conf
usage() {
diff --git a/src/bin/syspkg b/src/bin/syspkg
index 0132969..d7e554f 100755
--- a/src/bin/syspkg
+++ b/src/bin/syspkg
@@ -1,4 +1,22 @@
-#!/usr/bin/env /bin/sh
+#!/usr/bin/env sh
+
+# syspkg - merge a package into the system package index
+# This file is part of Glacier.
+#
+# Copyright (C) 2023 Everest Linux
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see .
source /etc/glacier.conf
if [ "$?" != "0" ]; then
diff --git a/src/etc/glacier.conf b/src/etc/glacier.conf
index db18c70..c77de79 100644
--- a/src/etc/glacier.conf
+++ b/src/etc/glacier.conf
@@ -12,7 +12,20 @@ export check="\xE2\x9C\x93"
export error="\xE2\x9C\x95"
# Command to be used for downloading packages
+# This command will be invoked whenever files need to be downloaded
export GLACIER_DOWNLOAD_BACKEND="wget --quiet --show-progress"
+# Permitted software licenses
+# Glacier will install software licensed under what's listed here. Otherwise, it'll quit.
+# Some common licenses are:
+# - GNU General Public License version 3 (GPL v3)
+# - MIT License (MIT)
+# - BSD License (BSD)
+# - Apache License (APACHE)
+# - Binary redistributable (BIN-REDIST)
+# - End-user-license-agreement (EULA)
+export GLACIER_ALLOWED_LICENSES=("GPL v3" "MIT" "BSD" "APACHE")
+
# Package repository
# WARNING: DO NOT SET OR CHANGE MANUALLY!!!
+# This variable is set by `glacier-mkprofile`, changing it will cause issues