forked from sourcegraph/src-cli
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcode_intel.go
More file actions
38 lines (29 loc) · 735 Bytes
/
code_intel.go
File metadata and controls
38 lines (29 loc) · 735 Bytes
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
package main
import (
"flag"
"fmt"
)
var codeintelCommands commander
func init() {
usage := `'src code-intel' manages code intelligence data on a Sourcegraph instance.
Usage:
src code-intel command [command options]
The commands are:
upload uploads an LSIF dump file
Use "src code-intel [command] -h" for more information about a command.
`
flagSet := flag.NewFlagSet("code-intel", flag.ExitOnError)
handler := func(args []string) error {
lsifCommands.run(flagSet, "src code-intel", usage, args)
return nil
}
// Register the command.
commands = append(commands, &command{
flagSet: flagSet,
aliases: []string{"code-intel"},
handler: handler,
usageFunc: func() {
fmt.Println(usage)
},
})
}