From 1cc320cfea23be43afb2bfe63f6729ee0ed29315 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Thu, 4 Jan 2018 14:13:46 -0200 Subject: Inception: ensure backup folder exists --- inception | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'inception') diff --git a/inception b/inception index 3bb9d78..a5e4c5f 100755 --- a/inception +++ b/inception @@ -34,8 +34,9 @@ function inception_init { # once the integrity of the apps repo is checked if [ -e "$HOME/.dotfiles" ]; then if [ ! -h "$HOME/.dotfiles" ] || [ "`readlink $HOME/.dotfiles`" != "apps/dotfiles" ]; then - mv $HOME/.dotfiles $BACKUPS/ - ( cd $HOME && ln -s $HOME/apps/dotfiles .dotfiles ) + mkdir -p $BACKUPS + mv $HOME/.dotfiles $BACKUPS/ + ( cd $HOME && ln -s $HOME/apps/dotfiles .dotfiles ) fi fi -- cgit v1.2.3