go-flags icon indicating copy to clipboard operation
go-flags copied to clipboard

IniParser: write 'func' options with "ini-name"

Open cdevienne opened this issue 6 years ago • 2 comments

If a 'ini-name' tag is set on the option, write it to file even if the option is a function.

cdevienne avatar Dec 12 '19 11:12 cdevienne

What is the idea behind this?

jessevdk avatar Jul 11 '20 11:07 jessevdk

I use the WriteIni function to generate a configuration file skeleton, in which I want to see all options, including some function based ones. Since that PR I modified my fork so the option is always commented. If meaningful I can update the PR. A more complete version of this PR would be to somehow store the value that was read from the configuration so a read/write of the configuration file is idempotent.

cdevienne avatar Jul 13 '20 12:07 cdevienne