<commit_before>// Copyright (c) 2016 <NAME>
// This file is licensed under the MIT license.
// See the LICENSE file for more information.

package main

import (
	"flag"
	"fmt"
	"os"
	"time"
)

func config() (jobDir string, sshTTL, sshKeepAlive time.Duration, file, logFile, telemetryEndpoint, perf string, once, quiet bool) {
	const (
		jobDirDefault            = "."
		sshTTLDefault            = time.Minute * 10
		sshKeepAliveDefault      = time.Second * 30
		logFileDefault           = ""
		telemetryEndpointDefault = ""
		defaultPerf              = ""
		fileDefault              = ""
		onceDefault              = false
		quietDefault             = false
	)

	flag.StringVar(&jobDir, "jobs", jobDirDefault, "Directory to watch for .job files.")
	flag.DurationVar(&sshTTL, "sshTTL", sshTTLDefault, "Time until an unused SSH connection is closed.")
	flag.DurationVar(&sshKeepAlive, "sshKeepAlive", sshKeepAliveDefault, "Time between SSH keep-alive requests.")
	flag.StringVar(&file, "file", fileDefault, "Job file to execute. Disables automatic pick-up of job files.")
	flag.BoolVar(&once, "once", onceDefault, "Run job only once, regardless of the schedule. Only in combination with -f.")
	flag.BoolVar(&quiet, "quiet", quietDefault, "Silence xCUTEr by turning off log messages. Command output is still printed. Overwrites -log.")
	flag.StringVar(&logFile, "log", logFileDefault, "Log file.")
	flag.StringVar(&telemetryEndpoint, "statsd", telemetryEndpointDefault, "UDP endpoint for statsd messages.")
	flag.StringVar(&perf, "perf", defaultPerf, "Perf endpoint.")

	help := flag.Bool("help", false, "Display this help")
	config := flag.Bool("config", false, "Display current configuration")

	flag.Parse()

	if *help {
		flag.PrintDefaults()
		os.Exit(0)
	}

	if *config {
		fmt.Println("jobs  :", jobDir)
		fmt.Println("sshTTL:", sshTTL)
		fmt.Println("file  :", file)
		fmt.Println("once  :", once)
		fmt.Println("quiet :", quiet)
		fmt.Println("log   :", logFile)
		os.Exit(0)
	}

	return
}<commit_msg>Add missing parameters to -config output<commit_after>// Copyright (c) 2016 <NAME>
// This file is licensed under the MIT license.
// See the LICENSE file for more information.

package main

import (
	"flag"
	"fmt"
	"os"
	"time"
)

func config() (jobDir string, sshTTL, sshKeepAlive time.Duration, file, logFile, telemetryEndpoint, perf string, once, quiet bool) {
	const (
		jobDirDefault            = "."
		sshTTLDefault            = time.Minute * 10
		sshKeepAliveDefault      = time.Second * 30
		logFileDefault           = ""
		telemetryEndpointDefault = ""
		defaultPerf              = ""
		fileDefault              = ""
		onceDefault              = false
		quietDefault             = false
	)

	flag.StringVar(&jobDir, "jobs", jobDirDefault, "Directory to watch for .job files.")
	flag.DurationVar(&sshTTL, "sshTTL", sshTTLDefault, "Time until an unused SSH connection is closed.")
	flag.DurationVar(&sshKeepAlive, "sshKeepAlive", sshKeepAliveDefault, "Time between SSH keep-alive requests.")
	flag.StringVar(&file, "file", fileDefault, "Job file to execute. Disables automatic pick-up of job files.")
	flag.BoolVar(&once, "once", onceDefault, "Run job only once, regardless of the schedule. Only in combination with -f.")
	flag.BoolVar(&quiet, "quiet", quietDefault, "Silence xCUTEr by turning off log messages. Command output is still printed. Overwrites -log.")
	flag.StringVar(&logFile, "log", logFileDefault, "Log file.")
	flag.StringVar(&telemetryEndpoint, "statsd", telemetryEndpointDefault, "UDP endpoint for statsd messages.")
	flag.StringVar(&perf, "perf", defaultPerf, "Perf endpoint.")

	help := flag.Bool("help", false, "Display this help")
	config := flag.Bool("config", false, "Display current configuration")

	flag.Parse()

	if *help {
		flag.PrintDefaults()
		os.Exit(0)
	}

	if *config {
		fmt.Println("jobs  :", jobDir)
		fmt.Println("sshTTL:", sshTTL)
		fmt.Println("file  :", file)
		fmt.Println("once  :", once)
		fmt.Println("quiet :", quiet)
		fmt.Println("log   :", logFile)
		fmt.Println("statsd:", telemetryEndpoint)
		fmt.Println("perf  :", perf)
		os.Exit(0)
	}

	return
}
{'fraction_non_alphanumeric': 0.1328314715881496, 'fraction_numerical': 0.0048567265662943174, 'mean_word_length': 3.6966932725199544, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '5132407', 'n_tokens_mistral': 1402, 'n_tokens_neox': 1281, 'n_words': 375}