chudkins / DSF

A script to automate working with EFI's Digital StoreFront
GNU General Public License v3.0
0 stars 0 forks source link

Global config file needed #35

Open chudkins opened 5 years ago

chudkins commented 5 years ago

Looks like JSON is the way to go here; it's semi-human-readable and handles custom/nested objects as well as XML. Sample config file added; will rename when it's final.

Add function, maybe called Get-Config or similar, that finds and loads the file if it exists. (If it doesn't exist, companion function Save-Config or similar should create it with default values.)

chudkins commented 5 years ago

Added JSON config file; contents of said file are still a work in progress.

chudkins commented 5 years ago

Let's go with Get-ConfigFile and New-ConfigFile to fit PowerShell expectations. Also, Get-ConfigSettings which will load global configuration settings from a file, if found, or create the file using default values if it doesn't exist.