Most of this can be done with $com... You could also use hash tables for settings (I use hash tables like a personal registry). The hash table saved files would be named for the current user logged in. Load the proper setting file on startup.

The hash tables also need to be saved anytime a change is made. To make this simple, instead of saving with each change, have a hash table entry to indicate that a change has been made, but not saved. Then check for this hash table entry with a timer that execute about every 5 seconds, save the table if it's found and delete the hash table entry.

A backup system is helpful too. When saving, rename the old file. When loading, if the regular setting file is missing, copy the backup to the regular name of the file, then load it.

Then just setup folder permissions properly.