summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2015-01-27 00:17:04 -0500
committerMatthias Clasen <mclasen@redhat.com>2015-01-27 00:17:04 -0500
commit81aa0fa4b22290f4c592381c573e9fa4d23a324b (patch)
treea6072c601efa4f3570d34712755666fc525b999f
parenteab32072c9a8b20c227d50865be67b12244bdd2b (diff)
downloadappstream-glib-81aa0fa4b22290f4c592381c573e9fa4d23a324b.tar.gz
Ignore stray branches
Eventually, we'll commit our appstream data in a ref in the repository, with a name like "appstream". Currently, that ref causes appstream-builder to choke and complain. To avoid that, only treat refs starting with app/ or runtime/ as bundles.
-rw-r--r--client/as-builder.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/client/as-builder.c b/client/as-builder.c
index 4a80fb6..feafe54 100644
--- a/client/as-builder.c
+++ b/client/as-builder.c
@@ -94,6 +94,10 @@ as_builder_setup_ostree (AsbContext *ctx, const gchar *ostree_repo, GError **err
if (!ostree_parse_refspec (refspec, &remote, &ref, error))
return FALSE;
+ if (!g_str_has_prefix (ref, "app/") &&
+ !g_str_has_prefix (ref, "runtime/"))
+ continue;
+
pkg = asb_package_ostree_new ();
asb_package_set_source (pkg, ref);
asb_package_ostree_set_repodir (ASB_PACKAGE_OSTREE (pkg), ostree_repo);