Fatal panics and aborts execution with exit code 1
(err error)
| 71 | |
| 72 | // Fatal panics and aborts execution with exit code 1 |
| 73 | func Fatal(err error) { |
| 74 | returnCode := 1 |
| 75 | if err == commander.ErrFlagError || err == commander.ErrCommandError { |
| 76 | returnCode = 2 |
| 77 | } |
| 78 | panic(&FatalError{ReturnCode: returnCode, Message: err.Error()}) |
| 79 | } |
| 80 | |
| 81 | // Config loads and returns current configuration |
| 82 | func (context *AptlyContext) Config() *utils.ConfigStructure { |
no test coverage detected