Skip to contentSkip to conversation

pre-commit: check .topdeps for valid branches

PATCH In review Uwe Kleine-König 2 participants 3 messages Jun 15, 2016 – Aug 13, 2016 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH 1/1 pre-commit: check .topdeps for valid branches

---
 hooks/pre-commit.sh |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
hooks/pre-commit.sh +3 -0
index 8e05a4e..1eae2e8 100644
@@ -52,6 +52,9 @@ BEGIN      { in_hunk = 0; }
 /^[^@ +-]/ { in_hunk = 0; }
 ' |
 	while read newly_added; do
+		ref_exists "$newly_added" ||
+			die "Invalid branch as dependent: $newly_added"
+
 		# deps can be non-tgish but we can't run recurse_deps() on them
 		ref_exists "refs/top-bases/$newly_added" ||
 			continue
Signature · 1 line
tg: (0f8cd77..) bw/check-valid-deps (depends on: bw/check-for-dep-cycle)
#2 lore raw

Hi Bert,

Quoted 16 lines
hooks/pre-commit.sh +3 -0
index 8e05a4e..1eae2e8 100644
@@ -52,6 +52,9 @@ BEGIN      { in_hunk = 0; }
 /^[^@ +-]/ { in_hunk = 0; }
 ' |
 	while read newly_added; do
+		ref_exists "$newly_added" ||
+			die "Invalid branch as dependent: $newly_added"
+
 		# deps can be non-tgish but we can't run recurse_deps() on them
 		ref_exists "refs/top-bases/$newly_added" ||
 			continue
Signature · 1 line
tg: (0f8cd77..) bw/check-valid-deps (depends on: bw/check-for-dep-cycle)

this patch doesn't apply to my branch. I'd say you didn't send out bw/check-for-dep-cycle (or I oversaw it).

Best regards
Uwe

Signature · 2 lines
Pengutronix e.K.                              | Uwe Kleine-König            |
Industrial Linux Solutions                    | http://www.pengutronix.de/  |
#3 lore raw

2009/6/4 Uwe Kleine-König <[email protected]>:

Quoted 12 lines

Hi Bert,

Quoted 10 lines
hooks/pre-commit.sh +0 -0
index 8e05a4e..1eae2e8 100644
@@ -52,6 +52,9 @@ BEGIN      { in_hunk = 0; }
  /^[^@ +-]/ { in_hunk = 0; }

 ' |
      while read newly_added; do
+             ref_exists "$newly_added" ||
+                     die "Invalid branch as dependent: $newly_added"

Quoted 8 lines
Quoted 6 lines

+

              # deps can be non-tgish but we can't run recurse_deps() on them
              ref_exists "refs/top-bases/$newly_added" ||
                      continue
--
tg: (0f8cd77..) bw/check-valid-deps (depends on: bw/check-for-dep-cycle)

this patch doesn't apply to my branch.  I'd say you didn't send out bw/check-for-dep-cycle (or I oversaw it).

I have forwarded it to you, but you may also want to clone my topgit tree at:

http://kgb2.thruhere.net/git/?p=bertw/topgit.git;a=summary

Now that repo.or.cz is up again, I will put this repo on this server next week.

Regards,
Bert

Quoted 3 lines

Best regards
Uwe