chiark
/
gitweb
/
~ian
/
topgit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
112f068
)
tg import: Remove tg_ prefixes from functions
author
Petr Baudis
<pasky@suse.cz>
Tue, 9 Sep 2008 22:06:14 +0000
(
00:06
+0200)
committer
Petr Baudis
<pasky@suse.cz>
Tue, 9 Sep 2008 22:06:14 +0000
(
00:06
+0200)
tg-import.sh
patch
|
blob
|
history
diff --git
a/tg-import.sh
b/tg-import.sh
index 910d30080abb498c89d216280104622a6c07700d..63d7e1bb7a3ccaf2ecf0246302d59dc69708ac2a 100644
(file)
--- a/
tg-import.sh
+++ b/
tg-import.sh
@@
-21,13
+21,13
@@
while [ -n "$1" ]; do
done
done
-
tg_
get_commit_msg()
+get_commit_msg()
{
commit="$1"
git log -1 --pretty=format:"From: %an <%ae>%n%n%s%n%n%b" "$commit"
}
{
commit="$1"
git log -1 --pretty=format:"From: %an <%ae>%n%n%s%n%n%b" "$commit"
}
-
tg_
get_branch_name()
+get_branch_name()
{
# nice sed script from git-format-patch.sh
commit="$1"
{
# nice sed script from git-format-patch.sh
commit="$1"
@@
-43,14
+43,14
@@
tg_get_branch_name()
git log -1 --pretty=format:"%s" "$commit" | sed -e "$titleScript"
}
git log -1 --pretty=format:"%s" "$commit" | sed -e "$titleScript"
}
-
tg_
process_commit()
+process_commit()
{
commit="$1"
{
commit="$1"
- branch_name=$(
tg_
get_branch_name "$commit")
+ branch_name=$(get_branch_name "$commit")
echo "Importing $commit to $branch_name"
tg create tp/"$branch_name"
git read-tree "$commit"
echo "Importing $commit to $branch_name"
tg create tp/"$branch_name"
git read-tree "$commit"
-
tg_
get_commit_msg "$commit" > .topmsg
+ get_commit_msg "$commit" > .topmsg
git add -f .topmsg .topdeps
git commit -C "$commit"
}
git add -f .topmsg .topdeps
git commit -C "$commit"
}
@@
-79,7
+79,7
@@
do
info "Merged already: $comment"
;;
*)
info "Merged already: $comment"
;;
*)
-
tg_
process_commit "$rev"
+ process_commit "$rev"
;;
esac
done
;;
esac
done