Skip to content

Commit

Permalink
respect headless mode in link_file
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanshelly committed Dec 1, 2020
1 parent f5a301d commit 8d366b4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 3 additions & 0 deletions infra/setup/bin/link_file
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ link_file() {
local overwrite='' backup='' skip='' action=''
local overwrite_all=false backup_all=false skip_all=false

# accept existing files silently when running headless
[[ -z $DOTFILES_SETUP_HEADLESS ]] || skip_all=true

if [ -f "$dst" ] || [ -d "$dst" ] || [ -L "$dst" ]; then
if [ "$overwrite_all" == "false" ] \
&& [ "$backup_all" == "false" ] \
Expand Down
5 changes: 0 additions & 5 deletions infra/setup/bin/symlink
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@ main() {

header "<< Symlinking >>"

local overwrite_all=false backup_all=false skip_all=false

# accept existing files silently when running headless
[[ -z $DOTFILES_SETUP_HEADLESS ]] || skip_all=true

[[ $INSTALL_GUI_SYMLINKS == true ]] && link_gui_files

return 0
Expand Down

0 comments on commit 8d366b4

Please sign in to comment.