get chris's nits.
This commit is contained in:
parent
3898556caa
commit
f534b85ee9
11
main.go
11
main.go
|
@ -75,10 +75,13 @@ func realMain() int {
|
|||
|
||||
// Enable checkpoint for panic reporting
|
||||
config, err := loadConfig()
|
||||
if err == nil {
|
||||
if !config.DisableCheckpoint {
|
||||
packer.CheckpointReporter.Enable(config.DisableCheckpointSignature)
|
||||
}
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Couldn't load config: %s", err)
|
||||
return 1
|
||||
}
|
||||
|
||||
if !config.DisableCheckpoint {
|
||||
packer.CheckpointReporter.Enable(config.DisableCheckpointSignature)
|
||||
}
|
||||
|
||||
// Create the configuration for panicwrap and wrap our executable
|
||||
|
|
|
@ -2,7 +2,6 @@ package packer
|
|||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"log"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
@ -56,7 +55,7 @@ func (c *CheckpointTelemetry) Enable(disableSignature bool) {
|
|||
func (c *CheckpointTelemetry) baseParams(prefix string) *checkpoint.ReportParams {
|
||||
version := packerVersion.Version
|
||||
if packerVersion.VersionPrerelease != "" {
|
||||
version += fmt.Sprintf("-%s", packerVersion.VersionPrerelease)
|
||||
version += "-" + packerVersion.VersionPrerelease
|
||||
}
|
||||
|
||||
return &checkpoint.ReportParams{
|
||||
|
@ -69,9 +68,6 @@ func (c *CheckpointTelemetry) baseParams(prefix string) *checkpoint.ReportParams
|
|||
}
|
||||
}
|
||||
|
||||
func (c *CheckpointTelemetry) log(m string, args ...interface{}) {
|
||||
}
|
||||
|
||||
func (c *CheckpointTelemetry) ReportPanic(m string) error {
|
||||
if !c.enabled {
|
||||
return nil
|
||||
|
|
Loading…
Reference in New Issue