summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2011-10-19 19:17:20 (GMT)
committer Denys Vlasenko <vda.linux@googlemail.com>2011-10-19 19:17:20 (GMT)
commit4ea37d62c2b90e360a97c43ffdb10afabaac46d9 (patch)
tree70a1af033aa6694beb460a4eecb2326f23c07df6
parentefd08bfa0adab3ae299be7abdd45161a15804a3b (diff)
downloadbusybox-4ea37d62c2b90e360a97c43ffdb10afabaac46d9.tar.gz
busybox-4ea37d62c2b90e360a97c43ffdb10afabaac46d9.tar.bz2
gen_build_files.sh: simplify "print everything up to INSERT line" part
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rwxr-xr-xscripts/gen_build_files.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/gen_build_files.sh b/scripts/gen_build_files.sh
index 1a3d3e9..c42fe9f 100755
--- a/scripts/gen_build_files.sh
+++ b/scripts/gen_build_files.sh
@@ -27,11 +27,11 @@ generate()
# rules re handling of "\n" in echo params.
printf "%s\n" "${header}"
# print everything up to INSERT line
- sed -n '/^INSERT$/q;1,/^INSERT$/p' "${src}"
+ sed -n '/^INSERT$/ q; p' "${src}"
# copy stdin to stdout
cat
# print everything after INSERT line
- sed -n '/^INSERT$/{:l;n;p;bl}' "${src}"
+ sed -n '/^INSERT$/ { :l; n; p; bl }' "${src}"
} >"${dst}.tmp"
if ! cmp -s "${dst}" "${dst}.tmp"; then
gen "${dst}"