<commit_before>// Copyright © 2015 <NAME> <<EMAIL>>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package main

import (
	"fmt"
	"os"
	"os/signal"
	"syscall"

	"github.com/golang/glog"
	"github.com/spf13/cobra"
	"github.com/spf13/pflag"

	"k8s.io/kubernetes/pkg/util"
)

const (
	FLAG_V             = "v"
	FLAG_STDERR_THRESH = "stderrthreshold"
	FLAG_RUN_ONCE      = "once"
	FLAG_DRY_RUN       = "dry-run"
	FLAG_SERVER        = "server"
	FLAG_CONFIG        = "config"
	FLAG_POLL_TIME     = "poll-time"
	FLAG_TEMPLATE      = "template"
)

func newCmd() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "kube-template",
		Short: "kube-template",
		Long:  "Watches Kubernetes for updates, writing output of a series of templates to files.",
		Run:   runCmd,
	}
	initCmd(cmd)
	return cmd
}

func initCmd(cmd *cobra.Command) {
	// Command-related flags set
	f := cmd.Flags()
	f.Bool(FLAG_DRY_RUN, false, "don't write template output, dump result to stdout")
	f.Bool(FLAG_RUN_ONCE, false, "run template processing once and exit")
	f.StringP(FLAG_SERVER, "s", "", "the address and port of the Kubernetes API server")<commit_msg>Returned back accidentally removed flag<commit_after>// Copyright © 2015 <NAME> <<EMAIL>>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package main

import (
	"fmt"
	"os"
	"os/signal"
	"syscall"
	"time"

	"github.com/golang/glog"
	"github.com/spf13/cobra"
	"github.com/spf13/pflag"

	"k8s.io/kubernetes/pkg/util"
)

const (
	FLAG_V             = "v"
	FLAG_STDERR_THRESH = "stderrthreshold"
	FLAG_RUN_ONCE      = "once"
	FLAG_DRY_RUN       = "dry-run"
	FLAG_SERVER        = "server"
	FLAG_CONFIG        = "config"
	FLAG_POLL_TIME     = "poll-time"
	FLAG_TEMPLATE      = "template"
)

func newCmd() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "kube-template",
		Short: "kube-template",
		Long:  "Watches Kubernetes for updates, writing output of a series of templates to files.",
		Run:   runCmd,
	}
	initCmd(cmd)
	return cmd
}

func initCmd(cmd *cobra.Command) {
	// Command-related flags set
	f := cmd.Flags()
	f.Bool(FLAG_DRY_RUN, false, "don't write template output, dump result to stdout")
	f.Bool(FLAG_RUN_ONCE, false, "run template processing once and exit")
	f.StringP(FLAG_SERVER, "s", "", "the address and port of the Kubernetes API server")
	f.DurationP(FLAG_POLL_TIME, "p", 15*time.Second, "Kubernetes API server poll time")
{'fraction_non_alphanumeric': 0.11802891708468574, 'fraction_numerical': 0.008262024195928003, 'mean_word_length': 3.4722955145118735, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '2377816', 'n_tokens_mistral': 1178, 'n_tokens_neox': 1127, 'n_words': 366}