...
1 package jsonnetx
2
3 import (
4 "github.com/spf13/cobra"
5 )
6
7 const GlobHelp = `Glob patterns supports the following special terms in the patterns:
8
9 Special Terms | Meaning
10 ------------- | -------
11 '*' | matches any sequence of non-path-separators
12 '**' | matches any sequence of characters, including path separators
13 '?' | matches any single non-path-separator character
14 '[class]' | matches any single non-path-separator character against a class of characters ([see below](#character-classes))
15 '{alt1,...}' | matches a sequence of characters if one of the comma-separated alternatives matches
16
17 Any character with a special meaning can be escaped with a backslash ('\').
18
19 #### Character Classes
20
21 Character classes support the following:
22
23 Class | Meaning
24 ---------- | -------
25 '[abc]' | matches any single character within the set
26 '[a-z]' | matches any single character in the range
27 '[^class]' | matches any single character which does *not* match the class
28 `
29
30
31 var RootCommand = &cobra.Command{
32 Use: "jsonnet",
33 Short: "Helpers for linting and formatting JSONNet code",
34 }
35
36
37 func RegisterCommandRecursive(parent *cobra.Command) {
38 parent.AddCommand(RootCommand)
39
40 RootCommand.AddCommand(FormatCommand)
41 RootCommand.AddCommand(LintCommand)
42 }
43
View as plain text