2019-12-03 22:51:03 +00:00
|
|
|
package output
|
|
|
|
|
2019-12-06 14:23:01 +00:00
|
|
|
import "github.com/fatih/color"
|
2019-12-03 22:51:03 +00:00
|
|
|
|
2019-12-03 23:10:42 +00:00
|
|
|
// Called at the very end, before terminating pancap
|
|
|
|
func Finalize() {
|
2019-12-06 14:23:01 +00:00
|
|
|
printer := color.New(color.Bold, color.BgBlack)
|
|
|
|
|
2019-12-03 23:10:42 +00:00
|
|
|
// Check if we snipped, to add a notice how to show the whole block
|
|
|
|
if DidSnip {
|
|
|
|
// We snipped - inform user about this process
|
2019-12-06 14:23:01 +00:00
|
|
|
printer.Println("Output is snipped at one or more positions. Add --full-output to avoid snipping.")
|
|
|
|
}
|
|
|
|
|
|
|
|
// Check if we skipped printing an empty block
|
|
|
|
if DidAvoidEmptyBlock {
|
|
|
|
// We did - inform user about this
|
|
|
|
printer.Println("Some submodule output was hidden. Add --print-empty-blocks to show it.")
|
2019-12-03 22:51:03 +00:00
|
|
|
}
|
2019-12-03 23:10:42 +00:00
|
|
|
}
|