-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.go
75 lines (68 loc) · 3.18 KB
/
main.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/*
* Copyright (c) 2020-2021 Ubisoft-Potato
*
* Anti 996 License Version 1.0 (Draft)
*
* Permission is hereby granted to any individual or legal entity obtaining a copy
* of this licensed work (including the source code, documentation and/or related
* items, hereinafter collectively referred to as the "licensed work"), free of
* charge, to deal with the licensed work for any purpose, including without
* limitation, the rights to use, reproduce, modify, prepare derivative works of,
* publish, distribute and sublicense the licensed work, subject to the following
* conditions:
*
* 1. The individual or the legal entity must conspicuously display, without
* modification, this License on each redistributed or derivative copy of the
* Licensed Work.
*
* 2. The individual or the legal entity must strictly comply with all applicable
* laws, regulations, rules and standards of the jurisdiction relating to
* labor and employment where the individual is physically located or where
* the individual was born or naturalized; or where the legal entity is
* registered or is operating (whichever is stricter). In case that the
* jurisdiction has no such laws, regulations, rules and standards or its
* laws, regulations, rules and standards are unenforceable, the individual
* or the legal entity are required to comply with Core International Labor
* Standards.
*
* 3. The individual or the legal entity shall not induce or force its
* employee(s), whether full-time or part-time, or its independent
* contractor(s), in any methods, to agree in oral or written form,
* to directly or indirectly restrict, weaken or relinquish his or
* her rights or remedies under such laws, regulations, rules and
* standards relating to labor and employment as mentioned above,
* no matter whether such written or oral agreement are enforceable
* under the laws of the said jurisdiction, nor shall such individual
* or the legal entity limit, in any methods, the rights of its employee(s)
* or independent contractor(s) from reporting or complaining to the copyright
* holder or relevant authorities monitoring the compliance of the license
* about its violation(s) of the said license.
*
* THE LICENSED WORK IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE COPYRIGHT
* HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
* OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN ANY WAY CONNECTION
* WITH THE LICENSED WORK OR THE USE OR OTHER DEALINGS IN THE LICENSED WORK.
*
*/
package main
import (
"os"
"github.com/cyka/kubectl-java/cmd"
"github.com/spf13/pflag"
"k8s.io/cli-runtime/pkg/genericclioptions"
)
func main() {
flags := pflag.NewFlagSet("kubectl-java", pflag.ExitOnError)
pflag.CommandLine = flags
javaCmd := cmd.NewKubeJavaCmd(genericclioptions.IOStreams{
In: os.Stdin,
Out: os.Stdout,
ErrOut: os.Stderr,
})
if err := javaCmd.Execute(); err != nil {
//todo handle err here
os.Exit(1)
}
}