From 42b144f79e16b6e8aed3b38bb8cf52bf0448b0bc Mon Sep 17 00:00:00 2001 From: "darin%meer.net" Date: Thu, 1 Sep 2005 18:41:11 +0000 Subject: [PATCH] fixes bug 306077 "do not package channel-prefs.js in MAR complete and partial patches" r=chase --- tools/update-packaging/make_full_update.sh | 9 ++++++++- tools/update-packaging/make_incremental_update.sh | 11 +++++++++-- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/tools/update-packaging/make_full_update.sh b/tools/update-packaging/make_full_update.sh index dc0488e19040..c662feffa9c5 100755 --- a/tools/update-packaging/make_full_update.sh +++ b/tools/update-packaging/make_full_update.sh @@ -57,6 +57,13 @@ make_add_instruction() { fi } +# List all files in the current directory, stripping leading "./" +# Skip the channel-prefs.js file as it should not be included in any +# generated MAR files (see bug 306077). +list_files() { + find . -type f ! -name "channel-prefs.js" | sed 's/\.\/\(.*\)/"\1"/' +} + archive="$1" targetdir="$2" workdir="$targetdir.work" @@ -64,7 +71,7 @@ manifest="$workdir/update.manifest" targetfiles="update.manifest" # Generate a list of all files in the target directory. -list=$(cd "$targetdir" && find . -type f | sed 's/\.\/\(.*\)/"\1"/') +list=$(cd "$targetdir" && list_files) eval "files=($list)" mkdir -p "$workdir" diff --git a/tools/update-packaging/make_incremental_update.sh b/tools/update-packaging/make_incremental_update.sh index 8fff3f328e52..3fc02b8d3b92 100755 --- a/tools/update-packaging/make_incremental_update.sh +++ b/tools/update-packaging/make_incremental_update.sh @@ -65,6 +65,13 @@ make_patch_instruction() { fi } +# List all files in the current directory, stripping leading "./" +# Skip the channel-prefs.js file as it should not be included in any +# generated MAR files (see bug 306077). +list_files() { + find . -type f ! -name "channel-prefs.js" | sed 's/\.\/\(.*\)/"\1"/' +} + archive="$1" olddir="$2" newdir="$3" @@ -73,9 +80,9 @@ manifest="$workdir/update.manifest" archivefiles="update.manifest" # Generate a list of all files in the target directory. -list=$(cd "$olddir" && find . -type f | sed 's/\.\/\(.*\)/"\1"/') +list=$(cd "$olddir" && list_files) eval "oldfiles=($list)" -list=$(cd "$newdir" && find . -type f | sed 's/\.\/\(.*\)/"\1"/') +list=$(cd "$newdir" && list_files) eval "newfiles=($list)" mkdir -p "$workdir"