Page MenuHomeFreeBSD

Fix etcupdate diff with POSIXLY_CORRECT set, add option to list changes files
ClosedPublic

Authored by lytboris_gmail.com on Wed, Apr 29, 11:07 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, May 18, 11:08 AM
Unknown Object (File)
Mon, May 18, 7:27 AM
Unknown Object (File)
Mon, May 18, 12:31 AM
Unknown Object (File)
Mon, May 18, 12:24 AM
Unknown Object (File)
Sun, May 17, 6:25 PM
Unknown Object (File)
Sun, May 17, 6:23 PM
Unknown Object (File)
Sun, May 17, 6:21 PM
Unknown Object (File)
Sun, May 17, 6:19 PM
Subscribers

Details

Summary

etcupdate diff fails to show any diffs when POSIXLY_CORRECT environment variable is set. Instead of showing a diff, etcupdate diff emits diff --help for each file that was altered locally. This happens due to misplacement of the second -L argument of diff command, it is treated by getopt_long as an error.

This proposal fixes this behavior simply moving the second -L argument into a proper place.

A new feature comes along with this fix: -l argument for a diff command alters the way it shows differences. Instead of printing full diff, it reports changed file the same way as added/removed files are reported.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable