There is some rustdoc-related code in compiletest that uses the diff command-line tool; however, it passes the --color flag to diff, which diff does not accept on my system (macOS). We should probably use git diff --no-index instead of diff since it will have colors and will automatically use a pager. We may also want to pass the --minimal flag to diff/git diff; the manual page says:
--minimal
Spend extra time to make sure the smallest possible diff is produced.
See also #79991 (comment).
cc @jyn514
There is some rustdoc-related code in compiletest that uses the
diffcommand-line tool; however, it passes the--colorflag todiff, whichdiffdoes not accept on my system (macOS). We should probably usegit diff --no-indexinstead ofdiffsince it will have colors and will automatically use a pager. We may also want to pass the--minimalflag todiff/git diff; the manual page says:See also #79991 (comment).
cc @jyn514