diff options
author | Ryan Lortie <desrt@desrt.ca> | 2010-07-18 23:29:24 -0400 |
---|---|---|
committer | Ryan Lortie <desrt@desrt.ca> | 2010-07-18 23:29:24 -0400 |
commit | 1086dc13815445f4a965f63105c79990dfec80fe (patch) | |
tree | 142ccc3670f7b3317028ff7559c33b2134968969 /bin | |
parent | 67cb6fa67a608ba5b778e6e0bba9578a0a6ab075 (diff) | |
download | dconf-1086dc13815445f4a965f63105c79990dfec80fe.tar.gz |
merge 'dconf-update' into 'dconf' utility
Diffstat (limited to 'bin')
-rw-r--r-- | bin/Makefile.am | 12 | ||||
-rw-r--r-- | bin/dconf-update.vala | 2 | ||||
-rw-r--r-- | bin/dconf.vala | 4 |
3 files changed, 8 insertions, 10 deletions
diff --git a/bin/Makefile.am b/bin/Makefile.am index 2f77617..ee64db7 100644 --- a/bin/Makefile.am +++ b/bin/Makefile.am @@ -1,14 +1,8 @@ AM_CFLAGS = -std=c89 -Wall -Wmissing-prototypes -Wwrite-strings INCLUDES = -I$(top_srcdir)/common -I$(top_srcdir)/engine -I$(top_srcdir)/client -I$(top_srcdir)/gvdb $(gio_CFLAGS) -bin_PROGRAMS = dconf dconf-update +bin_PROGRAMS = dconf -dconf_LDADD = ../client/libdconf.la $(gio_LIBS) - -dconf_update_VALAFLAGS = --pkg=posix --pkg=gio-2.0 -dconf_update_LDADD = $(gio_LIBS) -dconf_update_SOURCES = dconf-update.vala ../gvdb/gvdb-builder.c gvdb.vapi fixes.vapi - -dconf_VALAFLAGS = --pkg=gio-2.0 ../client/dconf.vapi +dconf_VALAFLAGS = --pkg=gio-2.0 ../client/dconf.vapi --pkg=posix --pkg=gio-2.0 dconf_LDADD = $(gio_LIBS) ../client/libdconf.la -dconf_SOURCES = dconf.vala +dconf_SOURCES = dconf.vala dconf-update.vala ../gvdb/gvdb-builder.c gvdb.vapi fixes.vapi diff --git a/bin/dconf-update.vala b/bin/dconf-update.vala index 9ea6057..4bfcd18 100644 --- a/bin/dconf-update.vala +++ b/bin/dconf-update.vala @@ -137,7 +137,7 @@ void update_all (string dirname) throws GLib.Error { } } -void main () { +void do_update () { try { update_all ("/etc/dconf/db"); } catch (GLib.Error e) { diff --git a/bin/dconf.vala b/bin/dconf.vala index 6276ba7..16c3e6f 100644 --- a/bin/dconf.vala +++ b/bin/dconf.vala @@ -44,6 +44,10 @@ void main (string[] args) { do_write (client, args[2], args[3]); break; + case "update": + do_update (); + break; + default: error ("unknown command"); break; |