Skip to content
This repository was archived by the owner on Mar 27, 2024. It is now read-only.
This repository was archived by the owner on Mar 27, 2024. It is now read-only.

Wrong diff labels output 'entries have been added to ...' #375

Closed
@gabyx

Description

@gabyx

Expected behavior

Correct naming what is added where.

Actual behavior

It reports something has been added to imageA, but its the other way round.
Output should be:

These entries have been added to bbbbb:latest:

The template is probably just wrong.

Information

  • container-diff version: v0.17.0 built from git bea7ad9
  • Operating system: macOS

Steps to reproduce the behavior

  1. FROM alpine:latest as A
    RUN touch A.txt
    
    
    FROM alpine:latest as B
    RUN touch B.txt
  2. docker build -f Dockerfile --target b -t bbbbb:latest . && \
    docker build -f Dockerfile --target b -t aaaaa:latest . 
  3. container-diff diff daemon://aaaaa:latest daemon://bbbbb:latest --type=file

  4. Output is misleading:

     -----File-----
    
     These entries have been added to aaaaa:latest:
     FILE          SIZE
     /B.txt        0
    
     These entries have been deleted from aaaaa:latest:
     FILE          SIZE
     /A.txt        0
    

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions