<commit_before>/*
   Package to wrap the CouchDB initialization for inclusion into the revel
   framework.

   Copyright (C) 2013  <NAME> <<EMAIL>>
   http://opensource.org/licenses/mit-license.php
  
*/

// Package lazyboy wraps a CouchDB connection into a module for use with the
// Revel framework.
package lazyboy

import (
	"code.google.com/p/couch-go"
	"fmt"
	"github.com/robfig/revel"
)

var Database couch.Database //couchdb database object
var DBUrl string

// AppInit pulls the configuration options out of the app.conf file in a Revel
// application and stores them locally for use in the database connection.
// For optional configurations their defaults are set if they are not
// configured. For required configurations and error message is created and a
// Panic is send to Revel to kill the application.
func AppInit() {
	var found bool //logic processing

	//get url from app.conf or error out
	url := ""
	if url, found = revel.Config.String("couchdb.url"); !found {<commit_msg>updated code for revel reorganization<commit_after>/*
   Package to wrap the CouchDB initialization for inclusion into the revel
   framework.

   Copyright (C) 2013  <NAME> <<EMAIL>>
   http://opensource.org/licenses/mit-license.php

*/

// Package lazyboy wraps a CouchDB connection into a module for use with the
// Revel framework.
package lazyboy

import (
	"code.google.com/p/couch-go"
	"fmt"
	"github.com/revel/revel"
)

var Database couch.Database //couchdb database object
var DBUrl string

// AppInit pulls the configuration options out of the app.conf file in a Revel
// application and stores them locally for use in the database connection.
// For optional configurations their defaults are set if they are not
// configured. For required configurations and error message is created and a
// Panic is send to Revel to kill the application.
func AppInit() {
	var found bool //logic processing

	//get url from app.conf or error out
	url := ""
	if url, found = revel.Config.String("couchdb.url"); !found {
{'fraction_non_alphanumeric': 0.08552958727001492, 'fraction_numerical': 0.003978120338140228, 'mean_word_length': 3.6466512702078524, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, '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': '1584701', 'n_tokens_mistral': 580, 'n_tokens_neox': 555, 'n_words': 252}