From fa2335eb50eb510c2810708974166cf89ad46f5c Mon Sep 17 00:00:00 2001 From: Perreal Guillaume <guillaume.perreal@irstea.fr> Date: Tue, 20 Aug 2019 18:00:02 +0200 Subject: [PATCH] =?UTF-8?q?phpstan-watch:=20am=C3=A9lioration=20des=20mess?= =?UTF-8?q?ages=20d'erreurs.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/phpstan-watch | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bin/phpstan-watch b/bin/phpstan-watch index b424f79..05bafdf 100755 --- a/bin/phpstan-watch +++ b/bin/phpstan-watch @@ -8,6 +8,9 @@ fi if ! INOTIFYWAIT="$(which inotifywait)"; then echo "inotifywait introuvable !" >&2 + if [[ -x /usr/lib/command-not-found ]]; then + /usr/lib/command-not-found inotifywait + fi exit 1 fi @@ -41,6 +44,11 @@ else fi TARGET="${1:-$HERE/src}" +if [[ ! -e "$TARGET" ]]; then + echo "$TARGET n'existe pas !" >&2 + exit 1 +fi + DIR="$(mktemp -d)" FIFO="$DIR/fifo" mkfifo "$FIFO" -- GitLab