diff options
author | axtloss <axtlos@getcryst.al> | 2024-05-28 19:43:28 +0200 |
---|---|---|
committer | axtloss <axtlos@getcryst.al> | 2024-05-28 19:43:28 +0200 |
commit | 85e5469362db3c3fb89f7dc3fbe1eb1431fb2fcc (patch) | |
tree | 3cf032b70d13885da40f73210abd7ef2fcb3a5e2 /src | |
parent | e2d8b96945423c14adbf7a54693f5064d5b157c1 (diff) | |
download | autodarkmode-85e5469362db3c3fb89f7dc3fbe1eb1431fb2fcc.tar.gz autodarkmode-85e5469362db3c3fb89f7dc3fbe1eb1431fb2fcc.tar.bz2 |
add license header
Diffstat (limited to 'src')
-rw-r--r-- | src/configuration.c | 19 | ||||
-rw-r--r-- | src/extString.c | 19 | ||||
-rw-r--r-- | src/main.c | 31 | ||||
-rw-r--r-- | src/sun.c | 19 |
4 files changed, 60 insertions, 28 deletions
diff --git a/src/configuration.c b/src/configuration.c index 81a5bbb..6196e26 100644 --- a/src/configuration.c +++ b/src/configuration.c @@ -1,3 +1,22 @@ +/* configuration.c + * + * Copyright 2024 axtlos <axtlos@disroot.org> + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 3 of the License only. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <https://www.gnu.org/licenses/>. + * + * SPDX-License-Identifier: GPL-3.0-only + */ + #include "configuration.h" #include "iniparser/src/iniparser.h" diff --git a/src/extString.c b/src/extString.c index 6538dac..b32b380 100644 --- a/src/extString.c +++ b/src/extString.c @@ -1,3 +1,22 @@ +/* extString.c + * + * Copyright 2024 axtlos <axtlos@disroot.org> + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 3 of the License only. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <https://www.gnu.org/licenses/>. + * + * SPDX-License-Identifier: GPL-3.0-only + */ + #include <stdlib.h> #include <string.h> #include <ctype.h> @@ -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); @@ -1,3 +1,22 @@ +/* sun.c + * + * Copyright 2024 axtlos <axtlos@disroot.org> + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 3 of the License only. + * + * This program 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <https://www.gnu.org/licenses/>. + * + * SPDX-License-Identifier: GPL-3.0-only + */ + #include <math.h> #include <glib.h> #include <stdbool.h> |