probably wanna do this instead of that yknow how it goes, once i test the 2020.04.06a it will go to main

This commit is contained in:
Ohio2 2021-04-06 02:30:28 +02:00
parent 3cdbc8e423
commit c19f2d8d31
2 changed files with 14 additions and 12 deletions

10
man
View file

@ -1,18 +1,18 @@
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.48.2.
.TH NOT "1" "April 2021" "not done yet lol" "User Commands"
.TH BUILD "1" "April 2021" "build 20.04.06a" "User Commands"
.SH NAME
not \- manual page for not done yet lol
build \- manual page for build 20.04.06a
.SH DESCRIPTION
sPKG via WGET, to cache, just type in (doas or sudo) spkg cache save
.SH "SEE ALSO"
The full documentation for
.B not
.B build
is maintained as a Texinfo manual. If the
.B info
and
.B not
.B build
programs are properly installed at your site, the command
.IP
.B info not
.B info build
.PP
should give you access to the complete manual.

16
spkg
View file

@ -1,14 +1,14 @@
#!/usr/bin/env sh
#sPKG via wget
#fuck spaghetti code
#mkay. gonna do a massive code overhaul!
# NOTE: sPKG via wget CAN'T RUN WITHOUT MAKE!!!
# ALNUX might not have MAKE!!! We tried porting it, dependiecies are fucked.
source=git.hippoz.xyz/spkg/repo
beta=false
case ${1} in
remove) pushd && cd /usr/src/${2} && make uninstall && popd ;;
install) case ${2} in
--root-dir=) pushd && mkdir /usr/src/${2} 2>/dev/null && wget $source/${2}/Makefile /usr/src/${2}/Makefile && cd /usr/src/${2} && make prepare && PREFIX=${3} make && make install && cat ${2} > /var/cache/spkg.cache && popd || echo 'Invalid package.' && popd ;;
*) pushd && mkdir /usr/src/${2} 2>/dev/null && wget $source/${2}/Makefile /usr/src/${2}/Makefile && cd /usr/src/${2} && make prepare && make && make install && cat ${2} > /var/cache/spkg.cache && popd || echo 'Invalid package.' && popd ;;
--root-dir=) pushd && mkdir /usr/src/${3} 2>/dev/null && wget $source/${3}/Makefile /usr/src/${3}/Makefile && cd /usr/src/${3} && make prepare && PREFIX=${4} make && make install && cat ${3} > /var/cache/spkg.cache && popd || echo 'Invalid package.' && popd ;;
*) pushd && mkdir /usr/src/${3} 2>/dev/null && wget $source/${3}/Makefile /usr/src/${3}/Makefile && cd /usr/src/${3} && make prepare && make && make install && cat ${3} > /var/cache/spkg.cache && ${3} --version > /var/cache/spkg.cache && popd || echo 'Invalid package.' && popd ;;
esac ;;
cache) case ${2} in
rm) rm -rf /usr/src/* ;;
@ -20,10 +20,12 @@ case ${1} in
database) case ${3} in
lookup) case ${4} in
local) grep ${5} /var/cache/spkg.cache ;;
query) wget $source/spkg.cache /tmp/spkg/ && grep ${5} /tmp/spkg/web.spkg.cache && rm /tmp/spkg/cache || mkdir -P /tmp/spkg && wget $source/spkg.cache /tmp/spkg/ && grep ${5} /tmp/spkg/web.spkg.cache && rm /tmp/spkg/cache;;
query) wget $source/spkg.cache /tmp/spkg/web.spkg.cache && grep ${5} /tmp/spkg/web.spkg.cache && rm /tmp/spkg/cache || mkdir 2>/dev/null /tmp/spkg && wget $source/spkg.cache /tmp/spkg/ && grep ${5} /tmp/spkg/web.spkg.cache && rm /tmp/spkg/cache;;
esac ;;
esac ;;
esac ;;
# a new update implementation, can't use it without beta, it can break shit so don't try it if you don't want it
update) [ $beta = false ] && echo "Beta is off, don't use this." || version1=$(wget $source/spkg.cache /tmp/spkg/web.spkg.cache && grep ${2}) && version2=$(wget $source/spkg.cache /tmp/spkg/web.spkg.cache && grep ${2} /tmp/spkg/web.spkg.cache ) && [ version1 = version2] && echo 'Up to date.' || pushd && mkdir /usr/src/${2} 2>/dev/null && wget $source/${2}/Makefile /usr/src/${2}/Makefile && cd /usr/src/${2} && make prepare && make && make install && cat ${2} > /var/cache/spkg.cache && ${2} --version > /var/cache/spkg.cache && popd ;;
--help) echo 'sPKG via WGET, to cache, just type in (doas or sudo) spkg cache save' ;;
--version) echo 'not done yet lol' ;;
--version) [ $beta = false ] && echo 'build 20.04.06a' || echo 'build 20.04.06a, BETA ON' ;;
esac