From fc9d27145f69a469a516a4e2a98667a4c2f4869e Mon Sep 17 00:00:00 2001 From: u Date: Fri, 12 Mar 2021 00:45:51 -0500 Subject: bashrc: get_spacemacs is more robust --- dot/bashrc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dot/bashrc b/dot/bashrc index b7e8af3..041b876 100644 --- a/dot/bashrc +++ b/dot/bashrc @@ -411,9 +411,10 @@ newfile() get_spacemacs() { if [ -d "$HOME/.emacs.d" ] - then return - else git clone --depth=1 https://github.com/syl20bnr/spacemacs ~/.emacs.d + then + rmdir "$HOME/.emacs.d" || return fi + git clone --depth=1 https://github.com/syl20bnr/spacemacs ~/.emacs.d } get_youtube-dl() -- cgit v1.2.3