diff options
author | Mattias Andrée <maandree@kth.se> | 2023-11-18 23:23:40 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2023-11-18 23:23:40 +0100 |
commit | 0f1df0db903ba576fd17b08197d3066af7a61e5f (patch) | |
tree | a59c04307b1382257afa3c3512ec3abadf7e0e47 /rust | |
parent | Use losetup -d instead of --detach and add clean up (diff) | |
download | dotfiles-0f1df0db903ba576fd17b08197d3066af7a61e5f.tar.gz dotfiles-0f1df0db903ba576fd17b08197d3066af7a61e5f.tar.bz2 dotfiles-0f1df0db903ba576fd17b08197d3066af7a61e5f.tar.xz |
A lot of changes
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'rust')
-rw-r--r-- | rust/Makefile | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/rust/Makefile b/rust/Makefile index cc81345..05911fb 100644 --- a/rust/Makefile +++ b/rust/Makefile @@ -1,21 +1,20 @@ .POSIX: -include ../common.mk install: if test -d ~/.cargo; then \ - test ! -d ~/.var/lib/cargo && \ + (test ! -e ~/.var/lib/cargo || test -L ~/.var/lib/cargo) && \ mkdir -p -- ~/.var/lib && \ mv ~/.cargo ~/.var/lib/cargo; \ else \ mkdir -p -- ~/.var/lib; \ fi - test ! -d ~/.config/profile.d/rust - ln -sf -- ~/.dotfiles/rust/user-profile ~/.config/profile.d/rust + test ! -e ~/.config/profile.d/cargo || test -L ~/.config/profile.d/cargo + ln -sf -- ~/.dotfiles/cargo/user-profile ~/.config/profile.d/cargo uninstall: + +! ../check-installed rust + +! ../check-installed cargo -rm -rf -- ~/.var/cache/cargo -rm -rf -- ~/.cargo -unlink -- ~/.config/profile.d/rust -rmdir -- ~/.config/profile.d - -.PHONY: install uninstall |