only os.Exits on error

This commit is contained in:
Victor Vieux
2013-09-09 21:26:35 +00:00
parent 9b088ada7e
commit 46a1cd69a9
3 changed files with 15 additions and 1 deletions
+9
View File
@@ -1012,3 +1012,12 @@ func (graph *DependencyGraph) GenerateTraversalMap() ([][]string, error) {
}
return result, nil
}
// An StatusError reports an unsuccessful exit by a command.
type StatusError struct {
Status int
}
func (e *StatusError) Error() string {
return fmt.Sprintf("Status: %d", e.Status)
}