forked from alnux/aps
add a suite of things
This commit is contained in:
parent
2ea5c8a809
commit
64de631b3f
5 changed files with 41 additions and 7 deletions
31
aps
31
aps
|
@ -1,4 +1,10 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
#################################
|
||||||
|
# Alnux Packaging System, #
|
||||||
|
# the package manager for Alnux #
|
||||||
|
#################################
|
||||||
|
|
||||||
if [ -f "/etc/al/config" ]; then
|
if [ -f "/etc/al/config" ]; then
|
||||||
. /etc/al/config
|
. /etc/al/config
|
||||||
else
|
else
|
||||||
|
@ -8,6 +14,10 @@ else
|
||||||
locpkg_database="${install_root}/var/aps/repos"
|
locpkg_database="${install_root}/var/aps/repos"
|
||||||
lock="${install_root}/var/aps/lock"
|
lock="${install_root}/var/aps/lock"
|
||||||
official="https://git.hippoz.xyz/alnux/repo"
|
official="https://git.hippoz.xyz/alnux/repo"
|
||||||
|
debug=off
|
||||||
|
fi
|
||||||
|
if [ ${debug} = on ]; then
|
||||||
|
set -x
|
||||||
fi
|
fi
|
||||||
die() {
|
die() {
|
||||||
echo "aps: fatal: ${1}"
|
echo "aps: fatal: ${1}"
|
||||||
|
@ -17,11 +27,11 @@ die() {
|
||||||
confirm(){
|
confirm(){
|
||||||
echo -ne "Are you sure? [Y/n] "
|
echo -ne "Are you sure? [Y/n] "
|
||||||
read prompt
|
read prompt
|
||||||
if [[ $prompt = [nN] ]]; then
|
if [[ ${prompt} = [nN] ]]; then
|
||||||
die "[E] User said no. Exiting..."
|
die "User said no. Exiting..."
|
||||||
elif [[ $prompt = [yY] ]]; then
|
elif [[ ${prompt} = [yY] ]]; then
|
||||||
else
|
else
|
||||||
die "[E] User gave invalid input. Exiting..."
|
die "User gave invalid input. Exiting..."
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
run_package_script() {
|
run_package_script() {
|
||||||
|
@ -140,6 +150,17 @@ upgrade() {
|
||||||
unset pkg_config_depends
|
unset pkg_config_depends
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
version(){
|
||||||
|
echo "Alnux APS v0.0.8"
|
||||||
|
}
|
||||||
|
help(){
|
||||||
|
echo "Alnux APS, the packaging system for Alnux."
|
||||||
|
echo ""
|
||||||
|
echo "sync - Synchronizes from package repository."
|
||||||
|
echo "install - Installs from local package information file and build file"
|
||||||
|
echo "upgrade - Upgrades from package repository."
|
||||||
|
echo "remove - Removes a package from /var/aps/installed and it's install files (payloadfiles)"
|
||||||
|
}
|
||||||
main() {
|
main() {
|
||||||
if [ -f "${lock}" ]; then
|
if [ -f "${lock}" ]; then
|
||||||
echo "[E] A lock file already exists (another instance of the package manager could be running). If you're sure no package manager is running, remove the file ${lock}."
|
echo "[E] A lock file already exists (another instance of the package manager could be running). If you're sure no package manager is running, remove the file ${lock}."
|
||||||
|
@ -158,6 +179,8 @@ main() {
|
||||||
[ -z "${2}" ] && exit 0
|
[ -z "${2}" ] && exit 0
|
||||||
install_package_from_repo "official" "${2}" ;;
|
install_package_from_repo "official" "${2}" ;;
|
||||||
upgrade) upgrade "official" ;;
|
upgrade) upgrade "official" ;;
|
||||||
|
help) help ;;
|
||||||
|
version) version ;;
|
||||||
*) die "[E] Invalid option ${1}, exiting..." ;;
|
*) die "[E] Invalid option ${1}, exiting..." ;;
|
||||||
esac
|
esac
|
||||||
rm "${lock}"
|
rm "${lock}"
|
||||||
|
|
|
@ -4,8 +4,9 @@
|
||||||
# Alnux Packaging System #
|
# Alnux Packaging System #
|
||||||
##########################
|
##########################
|
||||||
temp_location="/var/tmp"
|
temp_location="/var/tmp"
|
||||||
install_root="/var/tmp/alroot"
|
install_root="/"
|
||||||
installed_pkg_database="${install_root}/var/aps/installed"
|
installed_pkg_database="${install_root}/var/aps/installed"
|
||||||
locpkg_database="${install_root}/var/aps/repos"
|
locpkg_database="${install_root}/var/aps/repos"
|
||||||
lock="${install_root}/var/aps/lock"
|
lock="${install_root}/var/aps/lock"
|
||||||
official="https://git.hippoz.xyz/alnux/repo"
|
official="https://git.hippoz.xyz/alnux/repo"
|
||||||
|
debug=off
|
||||||
|
|
|
@ -17,5 +17,6 @@ else
|
||||||
install -v aps ${prefix}/usr/bin/ &&
|
install -v aps ${prefix}/usr/bin/ &&
|
||||||
install -v altools/sel ${prefix}/usr/bin/ &&
|
install -v altools/sel ${prefix}/usr/bin/ &&
|
||||||
install -v altools/repo ${prefix}/usr/bin/ &&
|
install -v altools/repo ${prefix}/usr/bin/ &&
|
||||||
install -v config/config ${prefix}/etc/al
|
install -v config/config ${prefix}/etc/al &&
|
||||||
|
install -v -Dm644 man/aps.8.gz ${prefix}/usr/share/man/man8/
|
||||||
fi
|
fi
|
||||||
|
|
BIN
man/aps.8.gz
Normal file
BIN
man/aps.8.gz
Normal file
Binary file not shown.
9
settings
Normal file
9
settings
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
UnlockClient=true
|
||||||
|
UnlockStudio=false
|
||||||
|
FPSCapValues=[30.000000, 60.000000, 75.000000, 120.000000, 144.000000, 165.000000, 240.000000, 360.000000]
|
||||||
|
FPSCapSelection=0
|
||||||
|
FPSCap=0.000000
|
||||||
|
CheckForUpdates=true
|
||||||
|
NonBlockingErrors=true
|
||||||
|
SilentErrors=false
|
||||||
|
QuickStart=false
|
Loading…
Reference in a new issue