usr

Modulate your userpace into POSIX-compliant shell scripts!
git clone git://clone.theohenson.com/usr.git
Log | Files | Refs | README

commit 1ab70ae42d3f76e62d317808944a90175b1bf65d
parent 3b067f2be3b60e5429cf7a52905442d6bde600bb
Author: Theo Henson <[email protected]>
Date:   Mon, 28 Dec 2020 17:36:37 -0500

Create modules

Diffstat:
Amodules/theo_pacman.mod.sh | 20++++++++++++++++++++
Amodules/theo_suk.mod.sh | 50++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 70 insertions(+), 0 deletions(-)

diff --git a/modules/theo_pacman.mod.sh b/modules/theo_pacman.mod.sh @@ -0,0 +1,20 @@ +theo_pacman_add() { + printf "theo_pacman: installing packages\n" + sudo pacman -S --needed --noconfirm --quiet libxinerama libxft libx11 freetype2 make gcc \ + neovim vim curl wget git dunst npm sxiv lxpolkit xorg fish xwallpaper picom sxhkd \ + xorg-xinit lxsession +} + +theo_pacman_remove() { +} + +theo_pacman_info() { + printf "Installs a set of packages with pacman that I (theo) like to have on most of my systems." +} + +theo_pacman_dirs() { +} + + +theo_pacman_files() { +} diff --git a/modules/theo_suk.mod.sh b/modules/theo_suk.mod.sh @@ -0,0 +1,50 @@ +theo_suk_add() { + printf "theo_suk: linking %s/src/suk\n" "$HOME" + ln -sf "$USR_DIR"/home/src/suk "$HOME"/src/suk + + printf "theo_suk: compiling software and linking binaries\n" + mkdir -p "$HOME"/.local/bin + for PROG in dwm st dwmblocks dmenu ; do + cd "$USR_DIR/home/src/suk/$PROG" || exit + make -j4 + ln -sf "$USR_DIR/home/src/suk/$PROG/$PROG" "$HOME/.local/bin/$PROG" + if [ "$PROG" = "dmenu" ] ; then + ln -sf "$USR_DIR/home/src/suk/$PROG/$PROG"_run "$HOME/.local/bin/$PROG"_run + ln -sf "$USR_DIR/home/src/suk/$PROG/$PROG"_path "$HOME/.local/bin/$PROG"_path + ln -sf "$USR_DIR/home/src/suk/$PROG/stest" "$HOME/.local/bin/stest" + fi + done +} + +theo_suk_remove() { + printf "theo_suk: unlinking %s/src/suk\n" "$HOME" + rm "$HOME"/src/suk + printf "theo_suk: unlinking binaries\n" + rm "$HOME"/.local/bin/st "$HOME"/.local/bin/dwm "$HOME"/.local/bin/dwmblocks \ + "$HOME"/.local/bin/dmenu "$HOME"/.local/bin/dmenu_run "$HOME"/.local/bin/dmenu_path \ + "$HOME"/.local/bin/stest +} + +theo_suk_info() { + printf "Installs my (theo's) build of some suckless software" +} + +theo_suk_dirs() { + printf "src/suk/dwmblocks src/suk/dwm src/suk/st src/suk/dmenu" +} + + +theo_suk_files() { + printf "src/suk/dwm/config.h src/suk/dwm/Makefile src/suk/dwm/config.mk + src/suk/dwm/drw.c src/suk/dwm/drw.h src/suk/dwm/dwm.c + src/suk/dwm/util.c src/suk/dwm/util.h + src/suk/st/config.h src/suk/st/Makefile src/suk/st/config.mk + src/suk/st/win.h src/suk/st/st.h src/suk/st/st.c + src/suk/st/x.c src/suk/st/arg.h + src/suk/dwmblocks/Makefile src/suk/dwmblocks/blocks.h + src/suk/dwmblocks/dwmblocks.c src/suk/dmenu/Makefile + src/suk/dmenu/arg.h src/suk/dmenu/config.h src/suk/dmenu/config.mk + src/suk/dmenu/dmenu.c src/suk/dmenu/dmenu_path src/suk/dmenu/dmenu_run + src/suk/dmenu/drw.c src/suk/dmenu/drw.h src/suk/dmenu/stest.c + src/suk/dmenu/util.c src/suk/dmenu/util.h" +}