In /usr/bin/diff2patches line 82: FILES=$(zcat "$diffgz" | lsdiff --strip 1 | egrep -v ^debian/) || \ ^---^ SC2196: egrep is non-standard and deprecated. Use grep -E instead. In /usr/bin/diff2patches line 86: [ ! -z "$file" ] || continue ^-- SC2236: Use -n instead of ! -z. In /usr/bin/diff2patches line 88: newFileName="$DEB_PATCHES/$(echo "$file" | sed 's#/#___#g').patch" ^----------------------------^ SC2001: See if you can use ${variable//search/replace} instead. For more information: https://www.shellcheck.net/wiki/SC2196 -- egrep is non-standard and depreca... https://www.shellcheck.net/wiki/SC2001 -- See if you can use ${variable//se... https://www.shellcheck.net/wiki/SC2236 -- Use -n instead of ! -z.