GuidanceOfGrace / CLASSIC-Fallout4

Crash Log Auto-Scanner & Setup Integrity Checker for Fallout 4 / Buffout 4. Tool that extensively scans Fallout 4 game & mod files and Buffout 4 crash logs, then provides troubleshooting advice depending on what it finds.
8 stars 4 forks source link

Command-line argument support for command-line script and convenience function for writing to ini file. #25

Closed evildarkarchon closed 1 year ago

evildarkarchon commented 1 year ago

This pull request adds command-line argument support for the command-line script. I also added a convenience function to make INI writing consistent and reduce code duplication and converted the existing code to use it. Right now, it imitates the behavior of the GUI, specifying a command-line argument will set the corresponding setting in the INI file. The if statements are constructed so that if you don't specify a command-line argument, it will respect your current INI setting, and it will not write to the INI file if the value specified is identical to what is already in the INI file. Also, if you specify a value that is not a directory to the Scan or INI paths, it will ignore it.

evildarkarchon commented 1 year ago

I did a scan today and discovered a missing \n in the material crash section so I added it here.