Skip to main content
1-Visitor
Dec 18, 2013 10:01 AM UTC
Solved

Get working revision and if modified by CLI

Hello

Is there a way by command line to get the working revision of a file in my sandbox and if it was modified from the original revision (means appear with Diff in the Sandbox View)?

Many thanks

Kind Regards

Thierry Dalon

    tdalonAnswer
    1-Visitor
    Dec 19, 2013 12:16 PM UTC

    Using si diff with --xmlapi I could workaround the hanging issue for binary files.

    (The --quiet flag does not work as expected here).

    The final solution looks like this:

    %Get working revision using:

    si revisioninfo --revision:working $file

    % Get diff status using:

    si diff -r wrev --xmlapi $file

    % Parsing the xml output to get the status

    3 replies

    tdalon1-VisitorAuthor
    1-Visitor
    Dec 18, 2013 11:59 AM UTC

    I've found a solution using

    si revisioninfo --revision=:working $file

    and

    si diff

    Translate
    tdalon1-VisitorAuthor
    1-Visitor
    Dec 18, 2013 8:49 PM UTC

    I have an issue with the si diff command on a binary file. It hangs.

    Does anyone know a workaround?

    Translate
    tdalon1-VisitorAuthorAnswer
    1-Visitor
    Dec 19, 2013 12:16 PM UTC

    Using si diff with --xmlapi I could workaround the hanging issue for binary files.

    (The --quiet flag does not work as expected here).

    The final solution looks like this:

    %Get working revision using:

    si revisioninfo --revision:working $file

    % Get diff status using:

    si diff -r wrev --xmlapi $file

    % Parsing the xml output to get the status

    Translate