[tracker/gsettings-rebased: 1/8] schemas: Add initial GSettings schemas



commit 9a09a6485c0e8b47ddade88b45da12f801c493b1
Author: Carlos Garnacho <carlosg gnome org>
Date:   Wed Feb 16 14:57:01 2011 +0100

    schemas: Add initial GSettings schemas

 configure.ac                                       |    3 +
 data/Makefile.am                                   |    2 +-
 data/gschemas/Makefile.am                          |   18 +++
 ...rg.freedesktop.Tracker.Extractor.gschema.xml.in |   35 +++++
 ...desktop.Tracker.Miner.FileSystem.gschema.xml.in |  146 ++++++++++++++++++++
 .../org.freedesktop.Tracker.Store.gschema.xml.in   |   28 ++++
 ...rg.freedesktop.Tracker.Writeback.gschema.xml.in |   28 ++++
 .../org.freedesktop.Tracker.gschema.xml.in         |   29 ++++
 src/libtracker-common/Makefile.am                  |    1 +
 src/libtracker-common/tracker-enums.h              |   34 +++++
 10 files changed, 323 insertions(+), 1 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 1f0c943..e587ab7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -94,6 +94,8 @@ AC_PROG_LN_S
 AC_PROG_INSTALL
 AC_PROG_MAKE_SET
 
+GLIB_GSETTINGS
+
 # Initialize libtool
 LT_PREREQ([2.2])
 LT_INIT([disable-static])
@@ -1961,6 +1963,7 @@ AM_CONDITIONAL(HAVE_MOCKUP, test "x$have_mockup" = "xyes")
 
 AC_CONFIG_FILES([
 	data/dbus/Makefile
+	data/gschemas/Makefile
 	data/icons/16x16/Makefile
 	data/icons/22x22/Makefile
 	data/icons/24x24/Makefile
diff --git a/data/Makefile.am b/data/Makefile.am
index 549e6cd..69c1092 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -1,6 +1,6 @@
 include $(top_srcdir)/Makefile.decl
 
-SUBDIRS = dbus languages icons ontologies miners
+SUBDIRS = dbus languages icons ontologies miners gschemas
 
 # First we fix the VERSION and libexecdir in the desktop files
 tracker-store.desktop.in: tracker-store.desktop.in.in
diff --git a/data/gschemas/Makefile.am b/data/gschemas/Makefile.am
new file mode 100644
index 0000000..c33c90b
--- /dev/null
+++ b/data/gschemas/Makefile.am
@@ -0,0 +1,18 @@
+gsettings_ENUM_NAMESPACE = org.freedesktop.Tracker
+gsettings_ENUM_FILES = $(top_srcdir)/src/libtracker-common/tracker-settings.h
+gsettings_SCHEMAS = \
+	org.freedesktop.Tracker.gschema.xml \
+	org.freedesktop.Tracker.Store.gschema.xml \
+	org.freedesktop.Tracker.Extractor.gschema.xml \
+	org.freedesktop.Tracker.Writeback.gschema.xml \
+	org.freedesktop.Tracker.Miner.FileSystem.gschema.xml
+
+ INTLTOOL_XML_NOMERGE_RULE@
+
+ GSETTINGS_RULES@
+
+CLEANFILES = $(gsettings_SCHEMAS)
+
+EXTRA_DIST = \
+	org.freedesktop.Tracker.enums.xml \
+	$(gsettings_SCHEMAS)
\ No newline at end of file
diff --git a/data/gschemas/org.freedesktop.Tracker.Extractor.gschema.xml.in b/data/gschemas/org.freedesktop.Tracker.Extractor.gschema.xml.in
new file mode 100644
index 0000000..4caf903
--- /dev/null
+++ b/data/gschemas/org.freedesktop.Tracker.Extractor.gschema.xml.in
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (C) 2011, Nokia <ivan frade nokia com>
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA  02110-1301, USA.
+-->
+<schemalist>
+  <schema id="org.freedesktop.Tracker.Extractor" path="/org/freedesktop/tracker/extractor/" gettext-domain="tracker">
+    <key name="verbosity" enum="org.freedesktop.Tracker.TrackerVerbosity">
+      <default>'errors'</default>
+      <_summary>Log verbosity</_summary>
+      <_description>Log verbosity.</_description>
+    </key>
+
+    <key name="max-bytes" type="i">
+      <_summary>Max bytes to extract</_summary>
+      <_description>Maximum number of UTF-8 bytes to extract.</_description>
+      <range min="0" max="10485760"/>
+      <default>1048576</default>
+    </key>
+  </schema>
+</schemalist>
diff --git a/data/gschemas/org.freedesktop.Tracker.Miner.FileSystem.gschema.xml.in b/data/gschemas/org.freedesktop.Tracker.Miner.FileSystem.gschema.xml.in
new file mode 100644
index 0000000..01ba2b1
--- /dev/null
+++ b/data/gschemas/org.freedesktop.Tracker.Miner.FileSystem.gschema.xml.in
@@ -0,0 +1,146 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (C) 2011, Nokia <ivan frade nokia com>
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA  02110-1301, USA.
+-->
+<schemalist>
+  <schema id="org.freedesktop.Tracker.Miner.FileSystem" path="/org/freedesktop/tracker/miners/fs/" gettext-domain="tracker">
+    <key name="verbosity" enum="org.freedesktop.Tracker.TrackerVerbosity">
+      <default>'errors'</default>
+      <_summary>Log verbosity</_summary>
+      <_description>Log verbosity.</_description>
+    </key>
+
+    <key name="initial-sleep" type="i">
+      <_summary>Initial sleep</_summary>
+      <_description>Initial sleep time, in seconds.</_description>
+      <range min="0" max="1000"/>
+      <default>15</default>
+    </key>
+
+    <key name="throttle" type="i">
+      <_summary>Throttle</_summary>
+      <_description>Indexing speed, the higher the slower.</_description>
+      <range min="0" max="20"/>
+      <default>0</default>
+    </key>
+
+    <key name="low-disk-space-limit" type="i">
+      <_summary>Low disk space limit</_summary>
+      <_description>Disk space threshold in MB at which to pause indexing, or -1 to disable.</_description>
+      <range min="-1" max="100"/>
+      <default>1</default>
+    </key>
+
+    <key name="crawling-interval" type="i">
+      <_summary>Crawling interval</_summary>
+      <_description>
+        Interval in days to check whether the filesystem is up to date in the database.
+	0 forces crawling anytime, -1 forces it only after unclean shutdowns, and -2
+	disables it entirely.
+      </_description>
+      <range min="-2" max="365"/>
+      <default>-1</default>
+    </key>
+
+    <key name="removable-days-threshold" type="i">
+      <_summary>Removable devices' data permanence threshold</_summary>
+      <_description>
+	Threshold in days after which files from removables devices
+	will be removed from database if not mounted. 0 means never,
+	maximum is 365.
+      </_description>
+      <range min="0" max="365"/>
+      <default>3</default>
+    </key>
+
+    <key name="enable-monitors" type="b">
+      <_summary>Enable monitors</_summary>
+      <_description>Set to false to completely disable any file monitoring</_description>
+      <default>true</default>
+    </key>
+
+    <key name="index-removable-devices" type="b">
+      <_summary>Index removable devices</_summary>
+      <_description>Set to true to enable indexing mounted directories for removable devices.</_description>
+      <default>true</default>
+    </key>
+
+    <key name="index-optical-discs" type="b">
+      <_summary>Index optical discs</_summary>
+      <_description>
+	Set to true to enable indexing CDs, DVDs, and generally optical media
+	(if removable devices are not indexed, optical discs won't be either)
+      </_description>
+      <default>false</default>
+    </key>
+
+    <key name="index-on-battery" type="b">
+      <_summary>Index when running on battery</_summary>
+      <_description>Set to true to index while running on battery</_description>
+      <default>false</default>
+    </key>
+
+    <key name="index-on-battery-first-time" type="b">
+      <_summary>Perform initial indexing when running on battery</_summary>
+      <_description>Set to true to index while running on battery for the first time only</_description>
+      <default>true</default>
+    </key>
+
+    <key name="index-recursive-directories" type="as">
+      <_summary>Directories to index recursively</_summary>
+      <_description>
+	List of directories to index recursively, Special values include:
+	&amp;DESKTOP, &amp;DOCUMENTS, &amp;DOWNLOAD, &amp;MUSIC, &amp;PICTURES,
+	&amp;PUBLIC_SHARE, &amp;TEMPLATES, &amp;VIDEOS.
+
+	See /etc/xdg/user-dirs.defaults and $HOME/.config/user-dirs.default
+      </_description>
+      <default>[ '&amp;DESKTOP', '&amp;DOCUMENTS', '&amp;DOWNLOAD', '&amp;MUSIC', '&amp;PICTURES', '&amp;VIDEOS' ]</default>
+    </key>
+
+    <key name="index-single-directories" type="as">
+      <_summary>Directories to index non-recursively</_summary>
+      <_description>
+	List of directories to index without inspecting subfolders, Special values include:
+	&amp;DESKTOP, &amp;DOCUMENTS, &amp;DOWNLOAD, &amp;MUSIC, &amp;PICTURES,
+	&amp;PUBLIC_SHARE, &amp;TEMPLATES, &amp;VIDEOS.
+
+	See /etc/xdg/user-dirs.defaults and $HOME/.config/user-dirs.default
+      </_description>
+      <default>[ '$HOME' ]</default>
+    </key>
+
+    <key name="ignored-files" type="as">
+      <_summary>Ignored files</_summary>
+      <_description>List of file patterns to avoid</_description>
+      <default>[ '*~', '*.o', '*.la', '*.lo' , '*.loT', '*.in', '*.csproj', '*.m4', '*.rej', '*.gmo', '*.orig', '*.pc', '*.omf', '*.aux', '*.tmp', '*.po', '*.vmdk', '*.vm*', '*.nvram', '*.part', '*.rcore', '*.lzo', 'autom4te', 'conftest', 'confstat', 'Makefile', 'SCCS', 'ltmain.sh', 'libtool', 'config.status', 'confdefs.h', 'configure' ]</default>
+    </key>
+
+    <key name="ignored-directories" type="as">
+      <_summary>Ignored directories</_summary>
+      <_description>List of directories to avoid</_description>
+      <default>[ 'po', 'CVS', 'core-dumps', 'lost+found' ]</default>
+    </key>
+
+    <key name="ignored-directories-with-content" type="as">
+      <_summary>Ignored directories with content</_summary>
+      <_description>Avoid any directory containing a file blacklisted here</_description>
+      <default>[ 'backup.metadata' ]</default>
+    </key>
+  </schema>
+</schemalist>
diff --git a/data/gschemas/org.freedesktop.Tracker.Store.gschema.xml.in b/data/gschemas/org.freedesktop.Tracker.Store.gschema.xml.in
new file mode 100644
index 0000000..bd4ac8d
--- /dev/null
+++ b/data/gschemas/org.freedesktop.Tracker.Store.gschema.xml.in
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (C) 2011, Nokia <ivan frade nokia com>
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA  02110-1301, USA.
+-->
+<schemalist>
+  <schema id="org.freedesktop.Tracker.Store" path="/org/freedesktop/tracker/store/" gettext-domain="tracker">
+    <key name="verbosity" enum="org.freedesktop.Tracker.TrackerVerbosity">
+      <default>'errors'</default>
+      <_summary>Log verbosity</_summary>
+      <_description>Log verbosity.</_description>
+    </key>
+  </schema>
+</schemalist>
diff --git a/data/gschemas/org.freedesktop.Tracker.Writeback.gschema.xml.in b/data/gschemas/org.freedesktop.Tracker.Writeback.gschema.xml.in
new file mode 100644
index 0000000..093e788
--- /dev/null
+++ b/data/gschemas/org.freedesktop.Tracker.Writeback.gschema.xml.in
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (C) 2011, Nokia <ivan frade nokia com>
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA  02110-1301, USA.
+-->
+<schemalist>
+  <schema id="org.freedesktop.Tracker.Writeback" path="/org/freedesktop/tracker/writeback/" gettext-domain="tracker">
+    <key name="verbosity" enum="org.freedesktop.Tracker.TrackerVerbosity">
+      <default>'errors'</default>
+      <_summary>Log verbosity</_summary>
+      <_description>Log verbosity.</_description>
+    </key>
+  </schema>
+</schemalist>
diff --git a/data/gschemas/org.freedesktop.Tracker.gschema.xml.in b/data/gschemas/org.freedesktop.Tracker.gschema.xml.in
new file mode 100644
index 0000000..98f7f12
--- /dev/null
+++ b/data/gschemas/org.freedesktop.Tracker.gschema.xml.in
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (C) 2011, Nokia <ivan frade nokia com>
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA  02110-1301, USA.
+-->
+<schemalist>
+  <schema id="org.freedesktop.Tracker" path="/org/freedesktop/tracker/">
+    <child name="store" schema="org.freedesktop.Tracker.Store"/>
+    <child name="extractor" schema="org.freedesktop.Tracker.Extractor"/>
+    <child name="writeback" schema="org.freedesktop.Tracker.Writeback"/>
+    <child name="miners" schema="org.freedesktop.Tracker.Miners"/>
+  </schema>
+
+  <schema id="org.freedesktop.Tracker.Miners" path="/org/freedesktop/tracker/miners/" />
+</schemalist>
diff --git a/src/libtracker-common/Makefile.am b/src/libtracker-common/Makefile.am
index eeaabe3..a5d2a2d 100644
--- a/src/libtracker-common/Makefile.am
+++ b/src/libtracker-common/Makefile.am
@@ -33,6 +33,7 @@ libtracker_common_la_SOURCES = \
 
 noinst_HEADERS = \
 	tracker-dbus.h \
+	tracker-enums.h \
 	tracker-ioprio.h \
 	tracker-log.h \
 	tracker-os-dependant.h \
diff --git a/src/libtracker-common/tracker-enums.h b/src/libtracker-common/tracker-enums.h
new file mode 100644
index 0000000..9121d1a
--- /dev/null
+++ b/src/libtracker-common/tracker-enums.h
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2011, Nokia <ivan frade nokia com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA  02110-1301, USA.
+ */
+
+#ifndef __TRACKER_ENUMS_H__
+#define __TRACKER_ENUMS_H__
+
+G_BEGIN_DECLS
+
+typedef enum {
+	TRACKER_VERBOSITY_ERRORS,
+	TRACKER_VERBOSITY_MINIMAL,
+	TRACKER_VERBOSITY_DETAILED,
+	TRACKER_VERBOSITY_DEBUG,
+} TrackerVerbosity;
+
+G_END_DECLS
+
+#endif /* __TRACKER_ENUMS_H__ */



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