blob: 5c26decb7718fc94a24a086d12c81607188446c7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
#!/bin/sh
REMOTE_BRANCH=packages/grub
LOCAL_BRANCH=upstream
CURRENT_BRANCH=`git rev-parse --abbrev-ref HEAD`
git checkout "$REMOTE_BRANCH"
git pull
git branch -f "$LOCAL_BRANCH" "$REMOTE_BRANCH"
git checkout "$LOCAL_BRANCH"
git filter-branch -f --subdirectory-filter trunk \
--tree-filter 'makepkg --printsrcinfo > .SRCINFO || rm .SRCINFO' \
--commit-filter '
if [ -e .SRCINFO ]
then
git commit-tree "$@"
else
shift
while [ -n "$1" ]
do
shift
map "$1"
shift
done
fi'
git checkout "$CURRENT_BRANCH"
|