summaryrefslogtreecommitdiffstats
path: root/scripts/combo-layer-hook-default.sh
diff options
context:
space:
mode:
authorYu Ke <ke.yu@intel.com>2011-06-13 20:20:53 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-07-08 17:52:27 +0100
commitb9ff62a0d0096138cb762ec5dbee9fd056999b70 (patch)
treed9dedb438d6fe596472958c7d83e7741433f0045 /scripts/combo-layer-hook-default.sh
parent4fadc30b92d42523fee013c168d47bc93dfe4fbd (diff)
downloadpoky-b9ff62a0d0096138cb762ec5dbee9fd056999b70.tar.gz
combo-layer-tool: add tool to manipulate combo layers
This patch adds the script "combo-layer" to manipulate combo layer repos. A combo layer repo is a repo containing multiple component repos, e.g. oe-core, bitbake, BSP repos. The combo layer repo needs to be updated by syncing with the component repo upstream. This script is written to assist the combo layer handling. The combo layer tool provides three functionalities: - init: when the combo layer repo and component repo does not exist, init will "git init" the combo layer repo, and also "git clone" the component repos - update: combo layer tool will pull the latest commit from component repo upstream, and apply the commits since last update commit to the combo repo. If the user specifies interactive mode(--interactive), they can edit the patch list to select which commits to apply. - splitpatch: split the combo repo commit into separate patches per component repo, to facilitate upstream submission. Combo layer tool uses a config file to define the component repo info. Please check the combo-layer.conf.example for a detailed explanation of the config file fields. (From OE-Core rev: 68394476748386e58f40173643967f5a248173b1) Signed-off-by: Yu Ke <ke.yu@intel.com> Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/combo-layer-hook-default.sh')
-rwxr-xr-xscripts/combo-layer-hook-default.sh13
1 files changed, 13 insertions, 0 deletions
diff --git a/scripts/combo-layer-hook-default.sh b/scripts/combo-layer-hook-default.sh
new file mode 100755
index 0000000000..f03c4fa80f
--- /dev/null
+++ b/scripts/combo-layer-hook-default.sh
@@ -0,0 +1,13 @@
1#!/bin/sh
2# Hook to add source component/revision info to commit message
3# Parameter:
4# $1 patch-file
5# $2 revision
6# $3 reponame
7
8patchfile=$1
9rev=$2
10reponame=$3
11
12sed -i -e "s#Subject: \[PATCH\] \(.*\)#Subject: \[PATCH\] $reponame: \1#" $patchfile
13sed -i -e "0,/Signed-off-by:/s#\(Signed-off-by:.*\)#\($reponame rev: $rev\)\n\n\1#" $patchfile