Closed caleb15 closed 1 year ago
Hi! I'm having the same problem, maybe it is worth noting that my image is on a private repo and uses a multi stage build?
diff --git a/runtime/ui/view/layer.go b/runtime/ui/view/layer.go
index c1f9d0c..b3ffc91 100644
--- a/runtime/ui/view/layer.go
+++ b/runtime/ui/view/layer.go
@@ -2,6 +2,7 @@ package view
import (
"fmt"
+ "strings"
"github.com/awesome-gocui/gocui"
"github.com/sirupsen/logrus"
"github.com/spf13/viper"
@@ -324,6 +325,9 @@ func (v *Layer) Render() error {
layerStr = fmt.Sprintf("%-4d", layer.Index)
} else {
layerStr = layer.String()
+ if i := strings.Index(layerStr, "\n"); i != -1 {
+ layerStr = layerStr[:i]
+ }
}
compareBar := v.renderCompareBar(idx)
May or may not be your problem: I have observed this in Dockerfiles with heredocs.
The JSON dumped by -j
shows all the layers I expect but in the GUI having any layers with a multiline string ends up hiding layers
the RUN echo 1
layer is missing and if I try to cursor down I'm either prevented, or in this case dive just exits.
If I apply the patch above it looks like this:
This is probably just me missing something obvious but with a image that has so many layers that it doesn't fit in the screen, the last few layers are not shown and I don't know how to get to them. I tried pressing the down arrow and page down and nothing happened.
As you can see in the image above there are more layers not displayed. Note that the image immediately above shows layers in reverse order (first layer at bottom, last layer on top)