Skip to content

--state option outputs metadata #508

Open
@Dogacel

Description

@Dogacel

From help,

    --state                     Only output diff state: no_changes,
                                incompatible, compatible

this doesn't align with reality. We had a case where the state outputted metadata.

Caused by this line:

System.out.println(result.isChanged().getValue());

We can simply

to include something like

public DiffResult toStateDiff() {
  if (this.isUnchanged()) {
    return DiffResult.UNCHANGED;
  }

 if (this.isCompatible()) {
    return DiffResult.COMPATIBLE;
 }

 return DiffResult.INCOMPATIBLE;
}

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions