2023-05-01 20:37:33 +02:00
|
|
|
# spmenuify
|
|
|
|
# Theme manager for spmenu
|
|
|
|
# https://git.speedie.site/spmenuify
|
|
|
|
#
|
|
|
|
# Copyright (C) 2022 speedie
|
|
|
|
#
|
|
|
|
# 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 <https://www.gnu.org/licenses/>.
|
|
|
|
|
2023-05-19 14:13:00 +02:00
|
|
|
VER = 0.2
|
2023-05-01 20:37:33 +02:00
|
|
|
DESTDIR = "/usr"
|
|
|
|
NAME = spmenuify
|
|
|
|
SHELL = /bin/sh
|
|
|
|
|
|
|
|
help:
|
|
|
|
@echo "make install Install ${NAME}."
|
|
|
|
@echo "make uninstall Uninstall ${NAME}."
|
|
|
|
@echo "make dist Create distro package for ${NAME}."
|
|
|
|
@echo "make pkg_arch Create packaging for Arch."
|
|
|
|
|
|
|
|
install:
|
|
|
|
cp ${NAME} spmenu_profile ${PREFIX}${DESTDIR}/bin
|
|
|
|
chmod +x ${PREFIX}${DESTDIR}/bin/${NAME} ${PREFIX}${DESTDIR}/bin/spmenu_profile
|
|
|
|
|
|
|
|
uninstall:
|
|
|
|
rm -rf ~/.config/${NAME}
|
|
|
|
rm -f ${PREFIX}${DESTDIR}/bin/${NAME}
|
|
|
|
|
2023-05-19 14:13:00 +02:00
|
|
|
clean:
|
|
|
|
rm -f *.zst* *.tar.gz ${NAME}-${VER}.PKGBUILD PKGBUILD.orig
|
|
|
|
|
|
|
|
dist: clean
|
2023-05-01 20:37:33 +02:00
|
|
|
mkdir -p ${NAME}-${VER}
|
2023-05-19 14:13:00 +02:00
|
|
|
cp ${NAME} spmenu_profile README.md LICENSE Makefile PKGBUILD buildconf build.sh ${NAME}-${VER}
|
2023-05-01 20:37:33 +02:00
|
|
|
tar -cf ${NAME}-${VER}.tar ${NAME}-${VER}
|
|
|
|
gzip ${NAME}-${VER}.tar
|
|
|
|
rm -rf ${NAME}-${VER}.tar ${NAME}-${VER}
|
|
|
|
|
|
|
|
pkg_arch: dist
|
|
|
|
command -v makepkg > /dev/null || exit 1
|
|
|
|
[ -f PKGBUILD ] || exit 1
|
|
|
|
cp -f PKGBUILD PKGBUILD.orig
|
2023-05-19 14:13:00 +02:00
|
|
|
sed -i "s/VERSION/${VER}/g; s/MD5SUM/$$(md5sum *.tar.gz | cut -d ' ' -f 1)/g" PKGBUILD
|
2023-05-01 20:37:33 +02:00
|
|
|
makepkg -sfr --sign || exit 1
|
|
|
|
rm -rf src/ pkg/ *.tar.gz
|
2023-05-19 14:13:00 +02:00
|
|
|
cp PKGBUILD ${NAME}-${VER}.PKGBUILD; mv PKGBUILD.orig PKGBUILD
|