[Libosinfo] [libosinfo PATCH 1/1] osinfo-detect: print os variants info for env format

2019-04-12 Thread Fabiano Fidêncio
Similarly to what's been done for the plain format, let's also print os variants' information when using --format=env. Signed-off-by: Fabiano Fidêncio --- tools/osinfo-detect.c | 47 ++- 1 file changed, 37 insertions(+), 10 deletions(-) diff --git

Re: [Libosinfo] [libosinfo PATCH 0/3] Make osinfo-detect aware of trees' os variants

2019-04-12 Thread Daniel P . Berrangé
On Fri, Apr 12, 2019 at 10:19:51AM +0200, Fabiano Fidêncio wrote: > This series makes osinfo-detect to behave in the very same way for both > medias and trees when those have a variant set. > > With the patches the tree detection of a Fedora Server tree will look > like: > fidencio@laerte

Re: [Libosinfo] [libosinfo PATCH 1/3] db: Set the os to the detected tree

2019-04-12 Thread Fabiano Fidêncio
On Fri, Apr 12, 2019 at 10:23 AM Daniel P. Berrangé wrote: > > On Fri, Apr 12, 2019 at 10:19:52AM +0200, Fabiano Fidêncio wrote: > > When detecting a tree, let's also its OS. > > word missing ? Fixed locally. "When detecting a tree, let's also set its OS".

Re: [Libosinfo] [libosinfo PATCH 3/3] osinfo-detect: Be aware of tree's os variants

2019-04-12 Thread Fabiano Fidêncio
On Fri, Apr 12, 2019 at 10:26 AM Daniel P. Berrangé wrote: > > On Fri, Apr 12, 2019 at 10:19:54AM +0200, Fabiano Fidêncio wrote: > > In the same way done for medias, make the tree detection aware of > > os-variants. > > > > https://gitlab.com/libosinfo/libosinfo/issues/25 > > > > Signed-off-by:

Re: [Libosinfo] [libosinfo PATCH 3/3] osinfo-detect: Be aware of tree's os variants

2019-04-12 Thread Daniel P . Berrangé
On Fri, Apr 12, 2019 at 10:19:54AM +0200, Fabiano Fidêncio wrote: > In the same way done for medias, make the tree detection aware of > os-variants. > > https://gitlab.com/libosinfo/libosinfo/issues/25 > > Signed-off-by: Fabiano Fidêncio > --- > tools/osinfo-detect.c | 30

Re: [Libosinfo] [libosinfo PATCH 1/3] db: Set the os to the detected tree

2019-04-12 Thread Daniel P . Berrangé
On Fri, Apr 12, 2019 at 10:19:52AM +0200, Fabiano Fidêncio wrote: > When detecting a tree, let's also its OS. word missing ? > > https://gitlab.com/libosinfo/libosinfo/issues/25 > > Signed-off-by: Fabiano Fidêncio > --- > osinfo/osinfo_db.c | 4 +++- >

[Libosinfo] [libosinfo PATCH 3/3] osinfo-detect: Be aware of tree's os variants

2019-04-12 Thread Fabiano Fidêncio
In the same way done for medias, make the tree detection aware of os-variants. https://gitlab.com/libosinfo/libosinfo/issues/25 Signed-off-by: Fabiano Fidêncio --- tools/osinfo-detect.c | 30 +- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git

[Libosinfo] [libosinfo PATCH 0/3] Make osinfo-detect aware of trees' os variants

2019-04-12 Thread Fabiano Fidêncio
This series makes osinfo-detect to behave in the very same way for both medias and trees when those have a variant set. With the patches the tree detection of a Fedora Server tree will look like: fidencio@laerte ~/src/upstream/libosinfo $ ./tools/osinfo-detect --type=tree

[Libosinfo] [libosinfo PATCH 1/3] db: Set the os to the detected tree

2019-04-12 Thread Fabiano Fidêncio
When detecting a tree, let's also its OS. https://gitlab.com/libosinfo/libosinfo/issues/25 Signed-off-by: Fabiano Fidêncio --- osinfo/osinfo_db.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/osinfo/osinfo_db.c b/osinfo/osinfo_db.c index 1089644..b7da2b7 100644 ---

[Libosinfo] [libosinfo PATCH 2/3] media, image, tree: Avoid critical errors when getting the os variants

2019-04-12 Thread Fabiano Fidêncio
When getting the os variant of media, image, or tree, let's ensure their OS is not NULL* before calling osinfo_os_get_variant_list(). In case it's NULL, let's just return NULL. *: having a media, image, or tree with no OS set is a common case when the user has been creating it manually.