.prettydiffrc file
Purpose of this file
This file allows users to save option configurations for the Pretty Diff tool. The file is run automatically when Pretty Diff is run as a Node.js application using its Node interface file, api/node-local.js.
Order of operations
Pretty Diff accepts options in various different ways. The first thing Pretty Diff looks for is if options are passed directly to the application, which can occur from another application or directly from the command line. The .prettdiffrc file is evaluated only after externally supplied options are evaluated. Each option has a default type and value that is applied if no other value is supplied. Finally, Pretty Diff accepts an option comment from the source file as the final and most dominate means of defining option values. This order of operations allows Pretty Diff to interpret options in the .prettydiffrc file conditionally in regards to certain other options.
Supported formats
The primary supported format is JSON. Simply supply JSON data containing the options to change and their intended values.
If the file is not JSON format the Pretty Diff's Node interface will evaluate the file as a JavaScript application using the supplied format. This is a more complex approach, but allows users to define options conditionally. This can be helpful if users wish to define one set of options a given language and another set of options for a different language, mode, or other combination of features.
File location
Pretty Diff will attempt to search for the file in two locations. The primary location is the current local directory of the executing application or user's command prompt. If Pretty Diff is installed both locally and globally the local configuration has dominance provided the command prompt is at that location.
If the .prettydiffrc file is not available at the user's locally active directory the application's local directory is searched.