aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-init.c
diff options
context:
space:
mode:
authorArturo Espinosa <unammx@src.gnome.org>2000-01-07 08:25:56 +0800
committerArturo Espinosa <unammx@src.gnome.org>2000-01-07 08:25:56 +0800
commitc80c14ffd0ace81afa80c82a137494900fcc0f14 (patch)
treee95ceb5354d6f6a96cd0bcd184710e657f1b2990 /shell/e-init.c
parent8e431aec558b7bdab46ff5c7519dd3776f816338 (diff)
downloadgsoc2013-evolution-c80c14ffd0ace81afa80c82a137494900fcc0f14.tar.gz
gsoc2013-evolution-c80c14ffd0ace81afa80c82a137494900fcc0f14.tar.zst
gsoc2013-evolution-c80c14ffd0ace81afa80c82a137494900fcc0f14.zip
More framework work -miguel
svn path=/trunk/; revision=1539
Diffstat (limited to 'shell/e-init.c')
-rw-r--r--shell/e-init.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/shell/e-init.c b/shell/e-init.c
new file mode 100644
index 0000000000..34ccdbcfc3
--- /dev/null
+++ b/shell/e-init.c
@@ -0,0 +1,34 @@
+/*
+ * e-init.c: Initializes Evolution for first time users
+ *
+ */
+#include <config.h>
+#include <gnome.h>
+#include "e-init.h"
+#include <sys/stat.h>
+#include <sys/types.h>
+#include <fcntl.h>
+#include <unistd.h>
+#include "e-util/e-gui-utils.h"
+
+char *evolution_base_dir;
+
+static void
+e_init_local (void)
+{
+ evolution_base_dir = g_concat_dir_and_file (g_get_home_dir (), "Evolution");
+
+ if (g_file_exists (evolution_base_dir))
+ return;
+
+ if (-1 == mkdir (evolution_base_dir, 0755)){
+ e_notice (NULL, GNOME_MESSAGE_BOX_ERROR, _("Evolution can not create its local folders"));
+ exit (0);
+ }
+}
+
+void
+e_init (void)
+{
+ e_init_local ();
+}