aboutsummaryrefslogtreecommitdiffstats
path: root/filesystem/Makefile
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--filesystem/Makefile22
1 files changed, 22 insertions, 0 deletions
diff --git a/filesystem/Makefile b/filesystem/Makefile
index c46eea2..c6b7fde 100644
--- a/filesystem/Makefile
+++ b/filesystem/Makefile
@@ -1,5 +1,18 @@
.POSIX:
+HIDE =\
+ Templates\
+ Desktop\
+ Public\
+ Documents\
+ Downloads\
+ Music\
+ Pictures\
+ Videos\
+ public_html\
+ password.gpg\
+ mnt
+
install:
mkdir -p -- ~/.config
mkdir -p -- ~/.var/cache/.thumbnails
@@ -53,6 +66,12 @@ install:
mkdir -p -- ~/.usr/share/man
mkdir -p -- ~/.usr/src
ln -sf -- ~/.dotfiles/filesystem/user-dirs.dirs ~/.config/
+ set -e && for f in $(HIDE); do \
+ test -e ~/.hidden && grep '^'"$$f"'$' < ~/.hidden || printf '%s\n' "$$f" >> ~/.hidden; \
+ done
+ if test "$$(hostname | tr '[[:upper:]]' '[[:lower:]]')" = zenith; then \
+ test -e ~/.hidden && grep '^cryptokey.gpg$' < ~/.hidden || printf '%s\n' "cryptokey.gpg" >> ~/.hidden; \
+ fi
uninstall:
-unlink -- ../.cache ~/.config/.cache
@@ -86,5 +105,8 @@ uninstall:
-rmdir -- ~/.usr/share
-rmdir -- ~/.usr/src
-rmdir -- ~/.usr
+ -for f in $(HIDE) cryptokey.gpg; do \
+ test ! -e ~/.hidden || grep -v '^'"$$f"'$' < ~/.hidden | sponge ~/.hidden; \
+ done
.PHONY: install uninstall