Merge pull request #47 from CarlJi/0627
doc: be consistent and remove noise
This commit is contained in:
commit
da04bb484c
@ -34,7 +34,7 @@ Build command will copy the project code and its necessary dependencies to a tem
|
||||
`,
|
||||
Example: `
|
||||
# Build the current binary with cover variables injected. The binary will be generated in the current folder.
|
||||
goc build
|
||||
goc build .
|
||||
|
||||
# Build the current binary with cover variables injected, and set the registry center to http://127.0.0.1:7777.
|
||||
goc build --center=http://127.0.0.1:7777
|
||||
|
@ -11,8 +11,6 @@ var (
|
||||
mode string
|
||||
debugGoc bool
|
||||
buildFlags string
|
||||
// packages string
|
||||
appArgs string
|
||||
|
||||
goRunExecFlag string
|
||||
goRunArguments string
|
||||
@ -41,7 +39,6 @@ func addBuildFlags(cmdset *pflag.FlagSet) {
|
||||
|
||||
func addRunFlags(cmdset *pflag.FlagSet) {
|
||||
addBuildFlags(cmdset)
|
||||
cmdset.StringVar(&appArgs, "appargs", "", "specify the application's arguments")
|
||||
cmdset.StringVar(&goRunExecFlag, "exec", "", "same as -exec flag in 'go run' command")
|
||||
cmdset.StringVar(&goRunArguments, "arguments", "", "same as 'arguments' in 'go run' command")
|
||||
// bind to viper
|
||||
|
@ -33,7 +33,7 @@ Install command will copy the project code and its necessary dependencies to a t
|
||||
`,
|
||||
Example: `
|
||||
# Install all binaries with cover variables injected. The binary will be installed in $GOPATH/bin or $HOME/go/bin if directory existed.
|
||||
goc install --packages="./..."
|
||||
goc install ./...
|
||||
|
||||
# Install the current binary with cover variables injected, and set the registry center to http://127.0.0.1:7777.
|
||||
goc install --center=http://127.0.0.1:7777
|
||||
|
@ -33,8 +33,9 @@ var runCmd = &cobra.Command{
|
||||
Short: "Run covers and runs the named main Go package",
|
||||
Long: `Run covers and runs the named main Go package,
|
||||
It is exactly behave as 'go run .' in addition of some internal goc features.`,
|
||||
Example: `
|
||||
Example: `
|
||||
goc run .
|
||||
goc run . [--buildflags] [--exec] [--arguments]
|
||||
`,
|
||||
Run: func(cmd *cobra.Command, args []string) {
|
||||
wd, err := os.Getwd()
|
||||
|
@ -165,7 +165,7 @@ func (c *PrComment) GetPrChangedFiles() (files []string, err error) {
|
||||
func GenCommentContent(commentPrefix string, delta cover.DeltaCovList) string {
|
||||
var buf bytes.Buffer
|
||||
table := tablewriter.NewWriter(&buf)
|
||||
table.SetHeader([]string{"File", "BASE Coverage", "New Coverage", "Delta"})
|
||||
table.SetHeader([]string{"File", "Base Coverage", "New Coverage", "Delta"})
|
||||
table.SetAutoFormatHeaders(false)
|
||||
table.SetBorders(tablewriter.Border{Left: true, Top: false, Right: true, Bottom: false})
|
||||
table.SetCenterSeparator("|")
|
||||
|
Loading…
Reference in New Issue
Block a user