Help - change the diff symbol "<", "|" or ">" to your desired?
The diff -w command is used to create a parallel comparison comparison file (instead of a parallel one).
Then I look through them using vi through the ssh terminal, the changes are indicated by either "<" or "|" or ">"
Since the file I'm viewing is the source code, moving to the changes alone,
using the above characters is difficult, as they are also in the source code C.
How can I change these default characters to the correct ones?
Kindly help. Thank.
According to my version of diff (2.8.1 from GNU diffutils from FSF) -w is used to change the width of the output; The -y option displays a side-by-side comparison. In combination, the two do not show any additional effect, except for the -y parameter, which is used alone, which means that you can have an alias in your terminal profile or in the global terminal profile that pseudonizes diff with diff -y.
, ( "<", "|" " > " ) -y. , . : -c () -u (). ( , diff Wikipedia. . diff man page.)
:
diff --old-group-format="(deleted)---" \
--new-group-format="(added)---" \
--changed-group-format="(updated)---" \
--unchanged-group-format="(nodiff)---" \
old_file.c new_file.c
, , () ---
, , () ---
, , () ---
, , (nodiff) ---
, , , script . . . line group , .
, , . GUI, Kompare.

