Skip to main content
1-Visitor
January 6, 2017
Question

SI command to compare remote and local file changes without MKS GUI

  • January 6, 2017
  • 1 reply
  • 4302 views

Hi Team,

We have integrated MKS Integrity client in our product. Need to generate report out of file changes by using MKS SI command.

Please let me know the command to compare remote and local file changes without MKS GUI.  I have tried to used "DIFF" command without gui but i am not sure where the files checked out in the filesystem. And i don't want to overwrite the local file changes also while checkout the file. Please let me know how to proceed further.Thanks.

    1 reply

    12-Amethyst
    January 10, 2017

    Provided that your file/member of interest resides withing the tree of a registered sandbox

    there should be no need to check out files for your use case.


    REM compare local member.c to current revision
    c:\sandbox\prj1\src> si diff member.c
    REM compare local member.c to revision 1.2
    c:\sandbox\prj1\src> si diff -r 1.2 member.c
    REM compare revision 1.2 and revision 1.3 of member.c
    c:\sandbox\prj1\src> si diff -r 1.2 -r 1.3 member.c

    Regards Juergen

    BTW:

    I dont know what you mean by "but i am not sure where the files checked out in the filesystem".

    Isn't this essential for finding out local changes?

    srathinam1-VisitorAuthor
    1-Visitor
    January 10, 2017

    Hi Klaus,

    Thanks for your response. Actually we need to generate report by comparing different file revision. What's changed in the local fileSystem(Integrated MKS in eclipse and editing it before checkin) and remote version.

    For diff command i must know the revision number to compare. How will i get only revision version number out of the file?.

    Thanks.

    12-Amethyst
    January 12, 2017

    If I'm guessing right you want to have the working revision in terms of INTEGRITY.

    (BTW: This is only available if you have a sandbox)

    The most simple method to memorize would be:


    si viewsandbox member.c

    This also outputs the working revision number.

    Unfortunately the output of this command is rather for human reading than for parsing.

    The following command should output only working revision number:


    si rlog --revision=:working --format="{workingrev}" --noHeaderFormat --noTrailerFormat member.c

    Regards

      Juergen

    BTW: I'm on Integrity 10.4