Fix bash shebang and recognise bash scripts as editable shell scripts when converting to deb. Closes: #532330 (Thanks, Bruce Stephens)

This commit is contained in:
Joey Hess
2009-06-08 13:22:30 -04:00
parent cbf330f982
commit 5b605e1960
3 changed files with 5 additions and 2 deletions

View File

@@ -738,7 +738,7 @@ sub postinst {
return $postinst unless %$owninfo;
my ($firstline, $rest)=split(/\n/, $postinst, 2);
if ($firstline !~ m/^#!\s*\/bin\/sh/) {
if ($firstline !~ m/^#!\s*\/bin\/(ba)?sh/) {
print STDERR "warning: unable to add ownership fixup code to postinst as the postinst is not a shell script!\n";
return $postinst;
}