Merge branch '10-no-permission-for-any-files-in-home-dir' into 'master'
Resolve "No permission for any files in home dir" Closes #10 See merge request marty-oehme/dotfiles!4
This commit is contained in:
commit
456859adfa
1 changed files with 4 additions and 4 deletions
|
@ -157,16 +157,16 @@ putgitrepo() { # Downlods a gitrepo $1 and places the files in $2 only overwriti
|
||||||
sudo -u "$name" git clone --bare "$1" "$dir/gitrepo" >/dev/null 2>&1 &&
|
sudo -u "$name" git clone --bare "$1" "$dir/gitrepo" >/dev/null 2>&1 &&
|
||||||
sudo -u "$name" cp -rfT "$dir/gitrepo" $dfdir/.dotfiles
|
sudo -u "$name" cp -rfT "$dir/gitrepo" $dfdir/.dotfiles
|
||||||
|
|
||||||
dotfiles $dfdir checkout
|
sudo -u "$name" dotfiles $dfdir checkout
|
||||||
if [ $? = 0 ]; then
|
if [ $? = 0 ]; then
|
||||||
echo "Checked out dotfiles.";
|
echo "Checked out dotfiles.";
|
||||||
else
|
else
|
||||||
echo "Backing up existing dotfiles.";
|
echo "Backing up existing dotfiles.";
|
||||||
mkdir -p $2/.dotfiles-backup
|
mkdir -p $2/.dotfiles-backup
|
||||||
dotfiles $dfdir checkout 2>&1 | egrep "\s+\." | awk {'print $1'} | xargs -I{} mv {} $2/.dotfiles-backup/{}
|
sudo -u "$name" dotfiles $dfdir checkout 2>&1 | egrep "\s+\." | awk {'print $1'} | xargs -I{} mv {} $2/.dotfiles-backup/{}
|
||||||
fi;
|
fi;
|
||||||
dotfiles $dfdir checkout
|
sudo -u "$name" dotfiles $dfdir checkout
|
||||||
dotfiles $dfdir config status.showUntrackedFiles no
|
sudo -u "$name" dotfiles $dfdir config status.showUntrackedFiles no
|
||||||
}
|
}
|
||||||
|
|
||||||
serviceinit() { for service in "$@"; do
|
serviceinit() { for service in "$@"; do
|
||||||
|
|
Loading…
Reference in a new issue