Add altools/sel, altools/repo, install.sh & add config file support. #8

Merged
hippoz merged 11 commits from Ohio2/aps:master into master 2021-08-25 14:46:01 +03:00
4 changed files with 34 additions and 1 deletions
Showing only changes of commit 6510fd4132 - Show all commits

13
altools/repo Normal file
View file

@ -0,0 +1,13 @@
#!/bin/sh
########################################
# Repo, a repository manager for alnux #
########################################
if [ $(whoami) != root ]; then
echo "[E] Run as root!"
kill 2
else
case $1 in
add) git clone https://${3}/${2}.git /var/aps/repos/${2} ;;
esac
fi

View file

@ -5,7 +5,8 @@
#########################
. "/etc/al/lnver.v"
case $1 in
linux) case $2 in
linux) if [ $(whoami) != root ]; then
case $2 in
list) ls /usr/src/ | grep 'linux' &&
ls -L /usr/src/linux 2>/dev/null
;;
@ -22,4 +23,5 @@ case $1 in
echo "pkg_config_depends=''" >> /var/aps/packages/linux/package
;;
esac
fi
esac

0
aps Normal file → Executable file
View file

18
install.sh Executable file
View file

@ -0,0 +1,18 @@
#!/bin/sh
##########################
# INSTALL SCRIPT FOR APS #
##########################
case $1 in
--prefix) prefix=$2 ;;
*) prefix=/
esac
if [ ${prefix} == / ]; then
if [ $(whoami) != root ]; then
echo '[E] You must run as root!'
kill 2
fi
else
install -v aps ${prefix}/usr/bin/ &&
install -v altools/sel ${prefix}/usr/bin/
fi