Blast-Radius Aware AI Code Review for Business-Critical Systems
LiveReview LiveReview Explore LiveReview

difference - compares two strings and prints a colorful diff

Description

difference  compares  the strings orig and edit and prints a colorful representation of the difference to
       the standard output.

Examples

       In the examples, text that would be printed in red is formatted  initalics,  and  text  that  would  be
       printed in green is formatted bold.

       Compare characters:
           $ difference--splitcharbrowngreenbgroween

       Compare words:
           $ difference--splitwordbrowngreenbrowngreen

           $  difference--splitword"Thequickbrownfoxjumpsoverthelazydog.""Thehugebrownfoxiscool."
           The quickhuge brown fox jumpsoverthelazydog.isreallycool.

       Compare lines:
           $ difference--splitwordbrowngreenbrowngreen

           $ difference--splitword"Thequickbrownfoxjumpsoverthelazydog.""Thehugebrownfoxiscool."Thequickbrownfoxjumpsoverthelazydog.Thehugebrownfoxiscool.

           $ difference--splitline"Rosesarered,violetsareblue,
           > Iwrotethislibraryhere,
           > justforyou.
           > (It'strue).""Rosesarered,violetsareblue,
           > Iwrotethisdocumentationhere,
           > justforyou.
           > (It'squitetrue)."
           Roses are red, violets are blue,
           Iwrotethislibraryhere,Iwrotethisdocumentationhere,
           just for you.
           (It'strue).(It'squitetrue).

                                                   2019-01-23                                      DIFFERENCE(1)

Name

       difference - compares two strings and prints a colorful diff

Options

-s, --splitchar|word|line
              Select the level of detail in the diff (default:  word).

Synopsis

difference [--splitsplit] origedit

See Also