Package: check-all-the-things
Version: 2017.05.20

CATS with the --mime option fails unhelpfully when the file package is not installed:

  % check-all-the-things --mime -c make-phony
  # common misspelling of .PHONY
  $ find . -type f \( -iname GNUmakefile -o -iname Makefile -o -iname '*.make' -o -iname '*.mk' -o -iwholename ./debian/rules \) -print0 
-o -exec sh -c 'file --mime-type -r0 "$1" | cut -d "" -f 2 | grep -qP "^: (?:(?s:text/x\-makefile)\Z)$" 
&& printf "%s\0" "$1"' sh {} \; | xargs -0 grep -nHEw '[.]PHONEY?'
  sh: 1: sh: file: not found
  sh: 1: sh: file: not found
  sh: 1: sh: file: not found
  ...

Please check for existence of the file executable before running any commands that require it.

--
Jakub Wilk

Reply via email to