text stringlengths 0 9.36M |
|---|
tip of "master". |
Let's look at this example: |
o---o---o---o---o---o---o---o---o---o "next" |
/ / / / |
/ a---a---b A / / |
/ / / / |
/ / c---c---c---c B / |
/ / / \ / |
/ / / b---b C \ / |
/ / / / \ / |
---o---o---o---o---o---o---o---o---o---o---o "master" |
A, B and C are topic branches. |
* A has one fix since it was merged up to "next". |
* B has finished. It has been fully merged up to "master" and "next", |
and is ready to be deleted. |
* C has not merged to "next" at all. |
We would want to allow C to be rebased, refuse A, and encourage |
B to be deleted. |
To compute (1): |
git rev-list ^master ^topic next |
git rev-list ^master next |
if these match, topic has not merged in next at all. |
To compute (2): |
git rev-list master..topic |
if this is empty, it is fully merged to "master". |
DOC_END |
File: .git/hooks/pre-applypatch.sample |
Contents: |
#!/bin/sh |
# |
# An example hook script to verify what is about to be committed |
# by applypatch from an e-mail message. |
# |
# The hook should exit with non-zero status after issuing an |
# appropriate message if it wants to stop the commit. |
# |
# To enable this hook, rename this file to "pre-applypatch". |
. git-sh-setup |
precommit="$(git rev-parse --git-path hooks/pre-commit)" |
test -x "$precommit" && exec "$precommit" ${1+"$@"} |
: |
File: .git/hooks/pre-receive.sample |
Contents: |
#!/bin/sh |
# |
# An example hook script to make use of push options. |
# The example simply echoes all push options that start with 'echoback=' |
# and rejects all pushes when the "reject" push option is used. |
# |
# To enable this hook, rename this file to "pre-receive". |
if test -n "$GIT_PUSH_OPTION_COUNT" |
then |
i=0 |
while test "$i" -lt "$GIT_PUSH_OPTION_COUNT" |
do |
eval "value=\$GIT_PUSH_OPTION_$i" |
case "$value" in |
echoback=*) |
echo "echo from the pre-receive-hook: ${value#*=}" >&2 |
;; |
reject) |
exit 1 |
esac |
i=$((i + 1)) |
done |
fi |
File: .git/refs/heads/master |
Contents: |
accf70fa8b5fb6219c3ac0f8e2f826412425fce6 |
File: .git/refs/remotes/origin/HEAD |
Contents: |
ref: refs/remotes/origin/master |
File: .git/objects/pack/pack-b2d8349658c2cb6f687142f22d80d9034655f2ea.pack |
Contents: |
PACK c.xmKo@ie5`y؉ |
0OÀ |
4Uvwq: JD&"q |
a,g%,,G("(DDCA-(`yED<s$ |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.