aboutsummaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
authoraxtloss <axtlos@getcryst.al>2024-05-28 19:43:28 +0200
committeraxtloss <axtlos@getcryst.al>2024-05-28 19:43:28 +0200
commit85e5469362db3c3fb89f7dc3fbe1eb1431fb2fcc (patch)
tree3cf032b70d13885da40f73210abd7ef2fcb3a5e2 /src/main.c
parente2d8b96945423c14adbf7a54693f5064d5b157c1 (diff)
downloadautodarkmode-85e5469362db3c3fb89f7dc3fbe1eb1431fb2fcc.tar.gz
autodarkmode-85e5469362db3c3fb89f7dc3fbe1eb1431fb2fcc.tar.bz2
add license header
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c31
1 files changed, 3 insertions, 28 deletions
diff --git a/src/main.c b/src/main.c
index b4b5330..2aa6e4b 100644
--- a/src/main.c
+++ b/src/main.c
@@ -22,20 +22,17 @@
#include "sun.h"
#include <string.h>
-#include <unistd.h>
#include <math.h>
#include <signal.h>
#include <glib.h>
#include <stdlib.h>
-#include <locale.h>
-#include <glib/gi18n.h>
#include <geoclue.h>
static GClueAccuracyLevel accuracy_level = GCLUE_ACCURACY_LEVEL_EXACT;
- GClueSimple *simple = NULL;
- GClueClient *client = NULL;
- GMainLoop *main_loop;
+GClueSimple *simple = NULL;
+GClueClient *client = NULL;
+GMainLoop *main_loop;
enum LocationType loctype = 0;
dictionary *dict = NULL;
@@ -145,28 +142,6 @@ gint
main (gint argc,
gchar *argv[])
{
- g_autoptr(GOptionContext) context = NULL;
- g_autoptr(GError) error = NULL;
- gboolean version = FALSE;
- GOptionEntry main_entries[] = {
- { "version", 0, 0, G_OPTION_ARG_NONE, &version, "Show program version" },
- { NULL }
- };
-
- context = g_option_context_new ("- my command line tool");
- g_option_context_add_main_entries (context, main_entries, NULL);
-
- if (!g_option_context_parse (context, &argc, &argv, &error))
- {
- g_printerr ("%s\n", error->message);
- return EXIT_FAILURE;
- }
-
- if (version)
- {
- g_printerr ("%s\n", PACKAGE_VERSION);
- return EXIT_SUCCESS;
- }
dict = load_config ();
loctype = config_get_location_type (dict);