From 3560d8be4b833e888e8386a3dc641fa164b4b808 Mon Sep 17 00:00:00 2001 From: gramanas Date: Sun, 22 Apr 2018 03:14:35 +0300 Subject: Add licence and copyright notice --- src/actionparser.c | 20 +++++++++++++++----- src/actionparser.h | 11 ++++++++--- src/actions.c | 9 +++++++-- src/actions.h | 12 +++++++++--- src/ck.c | 30 ++++++++++++++++++++++++++++++ src/confparser.c | 10 ++++++++++ src/confparser.h | 13 ++++++++++--- src/dblayer.c | 13 +++++++++++-- src/dblayer.h | 12 +++++++++--- 9 files changed, 109 insertions(+), 21 deletions(-) diff --git a/src/actionparser.c b/src/actionparser.c index cba732e..bfa4f5b 100644 --- a/src/actionparser.c +++ b/src/actionparser.c @@ -1,3 +1,18 @@ +/* actionparser.c - Action parser for ck -------------------------------*- C -*- + * + * This file is part of ck, the config keeper + * + * ----------------------------------------------------------------------------- + * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * ----------------------------------------------------------------------------- + * + * The following code is resposinble for parsing the command line arguments + * and report any errors that might come up. + * + * -------------------------------------------------------------------------- */ #define _GNU_SOURCE #include #include @@ -8,11 +23,6 @@ #include "actionparser.h" -/* -------------------------------------------------------------------------- - * The following code is resposinble for parsing the command line arguments - * and report any errors that might come up. - * -------------------------------------------------------------------------- */ - /* accepted commands */ /* [0] is the count */ const char* const strINIT[] = {"2", "init", "-i"}; diff --git a/src/actionparser.h b/src/actionparser.h index 854624b..be2416a 100644 --- a/src/actionparser.h +++ b/src/actionparser.h @@ -1,8 +1,13 @@ -/* actionparser.h - Action parser for ck------------------------*- C -*- +/* actionparser.h - Action parser for ck -------------------------------*- C -*- * * This file is part of ck, the config keeper * - * --------------------------------------------------------------------- + * ----------------------------------------------------------------------------- + * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * ----------------------------------------------------------------------------- * * The code here and in actionparser.c is responsible for parsing * the user's input from the command line and return a struct @@ -13,7 +18,7 @@ * printParserHelp() and printParserError() functions * to notify the user * - * ------------------------------------------------------------------ */ + * -------------------------------------------------------------------------- */ #ifndef ACTIONPARSER_H #define ACTIONPARSER_H diff --git a/src/actions.c b/src/actions.c index 98e161c..8941495 100644 --- a/src/actions.c +++ b/src/actions.c @@ -1,8 +1,13 @@ -/* actions.c - ck actions --------------------------------------*- C -*- +/* actions.c - ck actions ----------------------------------------------*- C -*- * * This file is part of ck, the config keeper * - * ------------------------------------------------------------------ */ + * ----------------------------------------------------------------------------- + * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * -------------------------------------------------------------------------- */ #include #include "actions.h" diff --git a/src/actions.h b/src/actions.h index f75dd80..b9d2192 100644 --- a/src/actions.h +++ b/src/actions.h @@ -1,11 +1,17 @@ -/* actions.h - Action parser for ck ----------------------------*- C -*- +/* actions.h - ck actions ----------------------------------------------*- C -*- * * This file is part of ck, the config keeper * - * --------------------------------------------------------------------- + * ----------------------------------------------------------------------------- * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) * - * ------------------------------------------------------------------ */ + * ----------------------------------------------------------------------------- + * + * + * + * -------------------------------------------------------------------------- */ #ifndef ACTIONS_H #define ACTIONS_H diff --git a/src/ck.c b/src/ck.c index d0fc135..01bc137 100644 --- a/src/ck.c +++ b/src/ck.c @@ -1,3 +1,33 @@ +/* ck.c - Main ck file -------------------------------------------------*- C -*- + * + * This file is part of ck, the config keeper + * + * ----------------------------------------------------------------------------- + * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * 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, either version 3 of the License, or + * (at your option) any later version. + * + * 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 . + * + * ----------------------------------------------------------------------------- + * + * This is the file where the main function lies. + * It first parses the user options and then runs the + * handles the list of user arguments to the run_ACTION functions. + * + * -------------------------------------------------------------------------- */ + #include #include #include diff --git a/src/confparser.c b/src/confparser.c index 2ffe701..62cfb8f 100644 --- a/src/confparser.c +++ b/src/confparser.c @@ -1,3 +1,13 @@ +/* confparser.h - Configuration file parser for ck ---------------------*- C -*- + * + * This file is part of ck, the config keeper + * + * ----------------------------------------------------------------------------- + * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * -------------------------------------------------------------------------- */ #include #include #include diff --git a/src/confparser.h b/src/confparser.h index 197ff3a..fad65d1 100644 --- a/src/confparser.h +++ b/src/confparser.h @@ -1,11 +1,18 @@ -/* confparser.h - Configuration file parser for ck -------------*- C -*- +/* confparser.h - Configuration file parser for ck ---------------------*- C -*- * * This file is part of ck, the config keeper * - * --------------------------------------------------------------------- + * ----------------------------------------------------------------------------- + * + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * ----------------------------------------------------------------------------- + * * The code here and in confparser.c is responsible parsing * the configuration and get the values set there - * ------------------------------------------------------------------ */ + * + * -------------------------------------------------------------------------- */ #ifndef CONFPARSER_H #define CONFPARSER_H diff --git a/src/dblayer.c b/src/dblayer.c index b781f47..5ece9c0 100644 --- a/src/dblayer.c +++ b/src/dblayer.c @@ -1,8 +1,17 @@ -/* dblayer.c - Database layer for ck ---------------------------*- C -*- +/* dblayer.c - Database layer for ck -----------------------------------*- C -*- * * This file is part of ck, the config keeper + * + * ----------------------------------------------------------------------------- * - * ------------------------------------------------------------------ */ + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) + * + * ----------------------------------------------------------------------------- + * + * Give access to the database. + * + * -------------------------------------------------------------------------- */ #include #include #include diff --git a/src/dblayer.h b/src/dblayer.h index d12118d..24fdc2b 100644 --- a/src/dblayer.h +++ b/src/dblayer.h @@ -1,11 +1,17 @@ -/* dblayer.h - Database layer for ck ---------------------------*- C -*- +/* dblayer.h - Database layer for ck -----------------------------------*- C -*- * * This file is part of ck, the config keeper + * + * ----------------------------------------------------------------------------- * - * --------------------------------------------------------------------- + * Copyright (C) 2018 Anastasis Grammenos + * GPLv3 (see LICENCE for the full notice) * + * ----------------------------------------------------------------------------- * - * ------------------------------------------------------------------ */ + * Give access to the database. + * + * -------------------------------------------------------------------------- */ #ifndef DBLAYER_H #define DBLAYER_H -- cgit v1.2.3