aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Rigby <john.rigby@linaro.org>2011-02-10 15:32:05 -0700
committerJohn Rigby <john.rigby@linaro.org>2011-03-16 16:05:42 -0600
commitedb49754c53f3ab43725fa3c41642144c0098607 (patch)
tree39a739f22d54e1bfbfc755a94bb22881d8d90d26
parentfc85be666810d7c2b640e60732674fbb4e388195 (diff)
LINARO: Improvements to mkflavourbranches
Cleanup config files after creating flavour branches Create temporary working branch automatically Signed-off-by: John Rigby <john.rigby@linaro.org>
-rw-r--r--debian.linaro/changelog1
-rwxr-xr-xdebian.linaro/scripts/mkflavourbranches26
2 files changed, 23 insertions, 4 deletions
diff --git a/debian.linaro/changelog b/debian.linaro/changelog
index 0db26fa393ed..7e630dccf060 100644
--- a/debian.linaro/changelog
+++ b/debian.linaro/changelog
@@ -29,6 +29,7 @@ linux-linaro (2.6.37-1003.6) UNRELEASED; urgency=low
- LP: #715835
* Rebase to linaro-linux-2.6.37-upstream-10Feb2011
- LP: #707038
+ * Add config cleanup and automatic tmp branch creation to mkflavourbranches
-- John Rigby <john.rigby@linaro.org> Tue, 08 Feb 2011 19:56:22 -0700
diff --git a/debian.linaro/scripts/mkflavourbranches b/debian.linaro/scripts/mkflavourbranches
index 0774000f999e..1469aa57d331 100755
--- a/debian.linaro/scripts/mkflavourbranches
+++ b/debian.linaro/scripts/mkflavourbranches
@@ -64,11 +64,25 @@ function do_flavour_branches {
done
git status
+ fakeroot ./debian/rules clean
+ fakeroot ./debian/rules updateconfigs
+ cat >> debian.linaro/config/armel/config.flavour.${common_flavour_prefix}-$flavour << END
+#
+# Single flavour kernel packages have no flavour dependent config options
+# look in ../config.common.ubuntu for full config
+#
+END
+ cat >> debian.linaro/config/armel/config.common.armel << END
+#
+# Single flavour kernel packages have no arch dependent config options
+# look in ../config.common.ubuntu for full config
+#
+END
+ git commit -s -m "LINARO: Cleanup configs after removing other flavours" debian.linaro/config
git commit -s -m "LINARO: Linaro-${source_pkg_version} $flavour only"
tagname="Linaro-${source_pkg_version}-${flavour}-only"
git tag -f -s -m "$tagname" $tagname HEAD
-
git push $remote_push -f HEAD:$flavour-only
git push $remote_push -f $tagname
@@ -79,9 +93,12 @@ function do_flavour_branches {
done
}
-test $# -eq 2 || fail "must provide working branch name and a pushable remote"
-working_branch=$1
-remote_push=$2
+test $# -eq 1 || fail "must provide a pushable remote"
+
+working_branch="tbranch$(dd 2>/dev/null if=/dev/urandom bs=10 count=1 | od -X | awk '{ print $2 }')"
+echo Using $working_branch as working branch name
+
+remote_push=$1
orig_branch=$(git symbolic-ref HEAD 2>/dev/null)
@@ -99,6 +116,7 @@ git push $remote_push -f $tagname
do_flavour_branches
git checkout $orig_branch
+git branch -D $working_branch
cleanup