[gnome-builder/wip/chergert/code-index-revamp] code-index: make directory tree before writing files



commit ed4b1b399896a3fb13c2bf381859ae3fd89c97ff
Author: Christian Hergert <chergert redhat com>
Date:   Sat Feb 2 01:47:41 2019 -0800

    code-index: make directory tree before writing files

 src/plugins/code-index/gbp-code-index-builder.c | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/src/plugins/code-index/gbp-code-index-builder.c b/src/plugins/code-index/gbp-code-index-builder.c
index fe79fe764..e27e2797d 100644
--- a/src/plugins/code-index/gbp-code-index-builder.c
+++ b/src/plugins/code-index/gbp-code-index-builder.c
@@ -481,6 +481,8 @@ gbp_code_index_builder_persist_async (GbpCodeIndexBuilder *self,
 
   file = g_file_get_child (self->index_dir, "SymbolKeys");
 
+  g_file_make_directory_with_parents (self->index_dir, cancellable, NULL);
+
   ide_persistent_map_builder_write_async (self->map,
                                           file,
                                           G_PRIORITY_DEFAULT,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]