mirror of
https://github.com/Project-OSS-Revival/alien.git
synced 2026-04-24 14:00:17 +00:00
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:
@@ -738,7 +738,7 @@ sub postinst {
|
|||||||
return $postinst unless %$owninfo;
|
return $postinst unless %$owninfo;
|
||||||
|
|
||||||
my ($firstline, $rest)=split(/\n/, $postinst, 2);
|
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";
|
print STDERR "warning: unable to add ownership fixup code to postinst as the postinst is not a shell script!\n";
|
||||||
return $postinst;
|
return $postinst;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -497,7 +497,7 @@ sub _script_helper {
|
|||||||
$value="#!/bin/bash\n$prefixcode$value";
|
$value="#!/bin/bash\n$prefixcode$value";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$value=~s@^#!\s*/bin/sh(\s)@#/bin/bash$1@;
|
$value=~s@^#!\s*/bin/sh(\s)@#!/bin/bash$1@;
|
||||||
$value=~s/\n/\n$prefixcode/s;
|
$value=~s/\n/\n$prefixcode/s;
|
||||||
}
|
}
|
||||||
$this->{$script} = $value;
|
$this->{$script} = $value;
|
||||||
|
|||||||
3
debian/changelog
vendored
3
debian/changelog
vendored
@@ -2,6 +2,9 @@ alien (8.76) UNRELEASED; urgency=low
|
|||||||
|
|
||||||
* Avoid using hostname -f for portability to unix systems,
|
* Avoid using hostname -f for portability to unix systems,
|
||||||
such as Solaris, where any options _set_ the hostname.
|
such as Solaris, where any options _set_ the hostname.
|
||||||
|
* Fix bash shebang and recognise bash scripts as editable
|
||||||
|
shell scripts when converting to deb. Closes: #532330
|
||||||
|
(Thanks, Bruce Stephens)
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Fri, 29 May 2009 13:02:54 -0400
|
-- Joey Hess <joeyh@debian.org> Fri, 29 May 2009 13:02:54 -0400
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user