Thread (18 messages) flat view 18 messages, 4 authors, 2016-06-15

Re: [PATCH v2] remote show: fix the -n option

From: Johannes Schindelin <hidden>
Date: 2016-06-15 22:44:43

Possibly related (same subject, not in this thread)

Hi,

On Mon, 9 Jun 2008, Olivier Marin wrote:
quoted hunk ↗ jump to hunk
diff --git a/builtin-remote.c b/builtin-remote.c
index c49f00f..efe74c7 100644
--- a/builtin-remote.c
+++ b/builtin-remote.c
@@ -421,10 +421,10 @@ static void show_list(const char *title, struct path_list *list)
 
 static int show_or_prune(int argc, const char **argv, int prune)
 {
-	int dry_run = 0, result = 0;
+	int no_query = 0, result = 0;
Just for the record (not that I think anybody will care): I do not like 
this change.
quoted hunk ↗ jump to hunk
@@ -442,21 +442,23 @@ static int show_or_prune(int argc, const char **argv, int prune)
 		struct transport *transport;
 		const struct ref *ref;
 		struct strbuf buf;
-		int i, got_states;
+		int i;
 
 		states.remote = remote_get(*argv);
 		if (!states.remote)
 			return error("No such remote: %s", *argv);
-		transport = transport_get(NULL, states.remote->url_nr > 0 ?
-			states.remote->url[0] : NULL);
-		ref = transport_get_remote_refs(transport);
-		transport_disconnect(transport);
 
 		read_branches();
-		got_states = get_ref_states(ref, &states);
-		if (got_states)
-			result = error("Error getting local info for '%s'",
-					states.remote->name);
And I do not like this change either.  It proliferates the "we just die() 
and do not care about reusing the code where die()ing is not desired" 
paradigm.

Sad,
Dscho
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help