settings: Save future changes in a dedicated file

This commit is contained in:
nemunaire 2022-05-26 22:54:46 +02:00
parent 465a48c1c0
commit 3c237819c3
5 changed files with 295 additions and 15 deletions

View file

@ -103,7 +103,7 @@ func ReadSettings(path string) (*Settings, error) {
}
// SaveSettings saves settings at the given location.
func SaveSettings(path string, s *Settings) error {
func SaveSettings(path string, s interface{}) error {
if fd, err := os.Create(path); err != nil {
return err
} else {