<commit_before>#include "che.h"
#include <stdio.h>
#include <string.h>

/* FIXME: use portable description */
#define CHEWING_HASH_PATH ".chewing"
#define PLAT_SEPARATOR "/"
#define HASH_FILE  "uhash.dat"

static char *hashfilename;

GtkWidget *main_window;

const char *get_hash_filename()
{
	static char *filename = NULL;
	const char hashfile[] = "/.chewing/uhash.dat";
	if (!filename) {
		const char *home = getenv("HOME");
		filename = malloc(strlen(home) + sizeof(hashfile) + 1);
		strcpy(filename, home);
		strcat(filename, hashfile);
	}
	return filename;
}

int main(int argc, char *argv[])
{
  GtkWidget *menu;
  GtkWidget *tree;
  GtkWidget *scroll;
  GtkWidget *vbox;

  /* load zhuin dictionary */
  zhuin_dictionary = zhuindict_loadfromfile(ZHUIN_DICTIONARY_FILE );
  if (!zhuin_dictionary)
    printf("WARNING: failed to load the zhuin database \"%s\"\n", ZHUIN_DICTIONARY_FILE);

  gtk_init(&argc, &argv);

  main_window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
  g_signal_connect (G_OBJECT (main_window), "delete_event",
		    G_CALLBACK (che_quit), NULL);
  gtk_window_set_default_size(GTK_WINDOW(main_window), 500, 400);
  vbox = gtk_vbox_new(FALSE, 5);
  gtk_container_add(GTK_CONTAINER(main_window), vbox);

  menu = che_create_menu(GTK_WINDOW(main_window));
  gtk_box_pack_start(GTK_BOX(vbox), menu, FALSE, TRUE, 0);
	
  /* new scrolled window */<commit_msg>Remove unused function 'get_hash_filename'.<commit_after>#include "che.h"
#include <stdio.h>
#include <string.h>

/* FIXME: use portable description */
#define CHEWING_HASH_PATH ".chewing"
#define PLAT_SEPARATOR "/"
#define HASH_FILE  "uhash.dat"

static char *hashfilename;

GtkWidget *main_window;

int main(int argc, char *argv[])
{
  GtkWidget *menu;
  GtkWidget *tree;
  GtkWidget *scroll;
  GtkWidget *vbox;

  /* load zhuin dictionary */
  zhuin_dictionary = zhuindict_loadfromfile(ZHUIN_DICTIONARY_FILE );
  if (!zhuin_dictionary)
    printf("WARNING: failed to load the zhuin database \"%s\"\n", ZHUIN_DICTIONARY_FILE);

  gtk_init(&argc, &argv);

  main_window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
  g_signal_connect (G_OBJECT (main_window), "delete_event",
		    G_CALLBACK (che_quit), NULL);
  gtk_window_set_default_size(GTK_WINDOW(main_window), 500, 400);
  vbox = gtk_vbox_new(FALSE, 5);
  gtk_container_add(GTK_CONTAINER(main_window), vbox);

  menu = che_create_menu(GTK_WINDOW(main_window));
  gtk_box_pack_start(GTK_BOX(vbox), menu, FALSE, TRUE, 0);
	
  /* new scrolled window */
{'fraction_non_alphanumeric': 0.12924071082390953, 'fraction_numerical': 0.006865912762520194, 'mean_word_length': 5.484293193717278, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '5285812', 'n_tokens_mistral': 995, 'n_tokens_neox': 937, 'n_words': 192}