After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 710967 - Add show operation to the remote command
Add show operation to the remote command
Status: RESOLVED FIXED
Product: ostree
Classification: Infrastructure
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: OSTree maintainer(s)
OSTree maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2013-10-27 17:19 UTC by Daniel Narvaez
Modified: 2013-10-28 13:15 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add a show operation to the remote command (2.72 KB, patch)
2013-10-27 17:22 UTC, Daniel Narvaez
committed Details | Review
additions on top to be squashed (1.18 KB, patch)
2013-10-27 20:58 UTC, Colin Walters
none Details | Review

Description Daniel Narvaez 2013-10-27 17:19:36 UTC
It's useful, for example, to copy the url from one repo to another. I will post a patch.
Comment 1 Daniel Narvaez 2013-10-27 17:22:50 UTC
Created attachment 258236 [details] [review]
Add a show operation to the remote command

Useful to get the remote url in scripts.
Comment 2 Colin Walters 2013-10-27 20:58:02 UTC
Review of attachment 258236 [details] [review]:

It'd be best if we had a generic "config" builtin like git has.  But let's not block this patch on that.

So this looks OK; but what do you think about calling it show-url?  There are potentially other values of interest like the tls-permissive or gpg-verify keys.
Comment 3 Colin Walters 2013-10-27 20:58:48 UTC
Created attachment 258248 [details] [review]
additions on top to be squashed

What do you think about these fixes on top?

* Rename to show-url
* Add space between identifier and paren per style
* Add a test case
Comment 4 Daniel Narvaez 2013-10-27 21:11:00 UTC
Review of attachment 258248 [details] [review]:

Looks good!

::: src/ostree/ot-builtin-remote.c
@@ +127,3 @@
       g_free (key);
     }
+  else if (!strcmp (op, "show-url"))

Yeah, I thought we could add the other properties to the output a bit like git is doing in show. Though then you need to parse the output... So I like show-url.