forked from operator-framework/operator-controller
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathroot.go
More file actions
40 lines (31 loc) · 841 Bytes
/
root.go
File metadata and controls
40 lines (31 loc) · 841 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
39
40
package main
import (
"github.com/spf13/cobra"
)
var rootCmd = &cobra.Command{
Use: "test-profile",
Short: "Test profiling tool for operator-controller",
Long: `Test profiling tool for collecting, analyzing, and comparing
heap and CPU profiles during operator-controller tests.
Examples:
# Run test with profiling
test-profile run baseline
# Start profiling daemon
test-profile start my-test
# Stop profiling daemon
test-profile stop
# Analyze collected profiles
test-profile analyze baseline
# Compare two runs
test-profile compare baseline optimized
# Collect single snapshot
test-profile collect`,
}
func init() {
rootCmd.AddCommand(runCmd)
rootCmd.AddCommand(startCmd)
rootCmd.AddCommand(stopCmd)
rootCmd.AddCommand(collectCmd)
rootCmd.AddCommand(analyzeCmd)
rootCmd.AddCommand(compareCmd)
}