<commit_before>/**
 * color.c -- functions related to custom color
 * Copyright (C) 2009-2015 by <NAME> <<EMAIL>>
 * GoAccess - An Ncurses apache weblog analyzer & interactive viewer
 *
 * 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 2 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.
 *
 * A copy of the GNU General Public License is attached to this
 * source distribution for its full text.
 *
 * Visit http://goaccess.prosoftcorp.com for new releases.
 */

#if HAVE_CONFIG_H
#include <config.h>
#endif

#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <term.h>

#include "color.h"

#include "commons.h"
#include "error.h"
#include "util.h"
#include "xmalloc.h"

static GSLList *color_list = NULL;
static GSLList *pair_list = NULL;

/* *INDENT-OFF* */
static GEnum CSTM_COLORS[] = {
  {"COLOR_MTRC_HITS"     , COLOR_MTRC_HITS}     ,
  {"COLOR_MTRC_VISITORS" , COLOR_MTRC_VISITORS} ,
  {"COLOR_MTRC_PERC"     , COLOR_MTRC_PERC}     ,
  {"COLOR_MTRC_BW"       , COLOR_MTRC_BW}       ,
  {"COLOR_MTRC_AVGTS"    , COLOR_MTRC_AVGTS}    ,
  {"COLOR_MTRC_CUMTS"    , COLOR_MTRC_CUMTS}    ,
  {"COLOR_MTRC_MAXTS"    , COLOR_MTRC_MAXTS}    ,
  {"COLOR_MTRC_PROT"     , COLOR_MTRC_PROT}     ,
  {"COLOR_MTRC_MTHD"     , COLOR_MTRC_MTHD}     ,
  {"COLOR_MTRC_DATA"     , COLOR_MTRC_DATA}     ,
  {"COLOR_MTRC_PERC_MAX" , COLOR_MTRC_PERC_MAX} ,
  {"COLOR_PANEL_COLS"    , COLOR_PANEL_COLS}    ,
  {"COLOR_BARS"          , COLOR_BARS}          ,
  {"COLOR_ERROR"         , COLOR_ERROR}         ,<commit_msg>Removed unnecessary term.h include.<commit_after>/**
 * color.c -- functions related to custom color
 * Copyright (C) 2009-2015 by <NAME> <<EMAIL>>
 * GoAccess - An Ncurses apache weblog analyzer & interactive viewer
 *
 * 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 2 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.
 *
 * A copy of the GNU General Public License is attached to this
 * source distribution for its full text.
 *
 * Visit http://goaccess.prosoftcorp.com for new releases.
 */

#if HAVE_CONFIG_H
#include <config.h>
#endif

#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>

#include "color.h"

#include "commons.h"
#include "error.h"
#include "util.h"
#include "xmalloc.h"

static GSLList *color_list = NULL;
static GSLList *pair_list = NULL;

/* *INDENT-OFF* */
static GEnum CSTM_COLORS[] = {
  {"COLOR_MTRC_HITS"     , COLOR_MTRC_HITS}     ,
  {"COLOR_MTRC_VISITORS" , COLOR_MTRC_VISITORS} ,
  {"COLOR_MTRC_PERC"     , COLOR_MTRC_PERC}     ,
  {"COLOR_MTRC_BW"       , COLOR_MTRC_BW}       ,
  {"COLOR_MTRC_AVGTS"    , COLOR_MTRC_AVGTS}    ,
  {"COLOR_MTRC_CUMTS"    , COLOR_MTRC_CUMTS}    ,
  {"COLOR_MTRC_MAXTS"    , COLOR_MTRC_MAXTS}    ,
  {"COLOR_MTRC_PROT"     , COLOR_MTRC_PROT}     ,
  {"COLOR_MTRC_MTHD"     , COLOR_MTRC_MTHD}     ,
  {"COLOR_MTRC_DATA"     , COLOR_MTRC_DATA}     ,
  {"COLOR_MTRC_PERC_MAX" , COLOR_MTRC_PERC_MAX} ,
  {"COLOR_PANEL_COLS"    , COLOR_PANEL_COLS}    ,
  {"COLOR_BARS"          , COLOR_BARS}          ,
  {"COLOR_ERROR"         , COLOR_ERROR}         ,
{'fraction_non_alphanumeric': 0.10612244897959183, 'fraction_numerical': 0.004591836734693878, 'mean_word_length': 3.4305084745762713, 'pattern_counts': {'":': 0, '<': 22, '<?xml version=': 0, '>': 22, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3566172', 'n_tokens_mistral': 1475, 'n_tokens_neox': 1434, 'n_words': 381}