Skip to content

Diff between Revisions #6

Closed
Closed

Description

@sfrique

Hello,

It would be great if it was possible to diff between already released versions.

Something like this, current release history:

$ helm history winsome-owl                                                                                                                                             [11:04:28]
REVISION        UPDATED                         STATUS          CHART           DESCRIPTION     
1               Wed Apr 12 18:23:28 2017        SUPERSEDED      api-0.1.0    Install complete
2               Wed Apr 12 18:25:55 2017        SUPERSEDED      api-0.1.0    Upgrade complete
3               Wed Apr 12 18:30:48 2017        SUPERSEDED      api-0.1.0    Upgrade complete
4               Wed Apr 12 18:32:39 2017        SUPERSEDED      api-0.1.0    Rollback to 2   
5               Thu Apr 13 00:08:00 2017        DEPLOYED        api-0.1.0    Upgrade complete

So to get a diff between revision 5 (current and 3)

$ helm diff winsome-owl 3

Or explicit get the diff between 4 and 1

$ helm diff winsome-owl 4-1

Thanks

Activity

  1. codenio commented on Dec 16, 2017

    @codenio
    Contributor

    Waiting for this feature..!!
    Mean while, as a work around , we could use the helm get and sdiff/vimdiff to view the difference between two revisions side by side.

    Using sdiff:

    $ sdiff <(helm get $release --revision $revision_1 ) <(helm get $release --revision $revision_2)

    To display only the changes use -s and -w flags

    $ sdiff -s -w 80 <(helm get $release --revision $revision_1 ) <(helm get $release --revision $revision_2)

    Using vimdiff:

    $ vimdiff <(helm get $release --revision $revision_1 ) <(helm get $release --revision $revision_2)

    Example:

    $ sdiff <(helm get my_release --revision 4 ) <(helm get my_release --revision 5 )
    REVISION: 4						      |	REVISION: 5
    RELEASED: Fri Dec 15 08:59:48 2017			      |	RELEASED: Fri Dec 15 09:02:09 2017
    ...                                                           | ....
  2. codenio commented on Jan 21, 2018

    @codenio
    Contributor

    hi @sfrique,
    I have implemented the above mentioned feature in this PR #21, have a look and let me know in case of corrections/bugs.

  3. sfrique commented on Jan 21, 2018

    @sfrique
    Author

    @aananthraj Thanks a lot to take sometime to implement this!

    Unfortunately I don't have the time to test it now =/
    But when i get a change i will.

    I am currently working on some charts, I may try to use this to see if it will help!

    Thanks again for the effort!

  4. codenio commented on Mar 12, 2018

    @codenio
    Contributor

    @sfrique any updates..?
    your inputs would be helpful for closing this issue.

  5. sfrique commented on Mar 13, 2018

    @sfrique
    Author

    I will test it at beginning of April.
    Sorry about the long delay.

  6. sfrique commented on Mar 30, 2018

    @sfrique
    Author

    @aananthraj this PR says it's messed up.
    What should i do?

  7. codenio commented on Apr 5, 2018

    @codenio
    Contributor

    @sfrique , can you be brief..?, couldn't understand.
    Is PR #22 messed up...?

  8. sfrique commented on Apr 5, 2018

    @sfrique
    Author

    @aananthraj i was checking PR #21
    Sorry, will test once i have some time!

  9. added a commit that references this issue on Apr 26, 2018
  10. databus23 commented on Apr 26, 2018

    @databus23
    Owner

    I believe this has been fixed by a536dfc and is shipped since version 2.9.0+1 of this plugin.

  11. PhilipSchmid commented on Aug 30, 2021

    @PhilipSchmid

    Small note to the comment from @codenio: You know have to use helm get values since helm get alone does not have a --revision flag (anymore?) (tested with Helm v3.6.0). Example:

    vimdiff <(helm get values prometheus-operator --revision 14) <(helm get values prometheus-operator --revision 13)
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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