sublime_guard icon indicating copy to clipboard operation
sublime_guard copied to clipboard

Allow for the --force-polling guard parameter.

Open davidhooey opened this issue 11 years ago • 0 comments

On some systems the rb-fsevent gem is not doing its job and the --force-polling parameter is required. I hacked the script to allow for --force-polling.

function run_guard() {
  cmd="guard --force-polling"
  cd "$1"
  if [[ $? -eq 0 ]] ; then
    if [[ -s "Gemfile" ]] ; then
      cmd="bundle exec guard --force-polling"
    fi
    printf "Running '$cmd'. All output/failures from this point on is from the '$cmd' command.\n\n"
    $cmd
  else
    printf "Failed to change into project root directory '$1', guard could not be started.\n\n"
  fi
}

davidhooey avatar Jan 22 '14 14:01 davidhooey