Open ion1 opened 8 years ago
thanks @ion1, sounds like a good direction.
We've also gotten requests for:
(i'm not so sold on changing the format, but conceivable).
Also, since the repo is moving most of its contents to be represented as ipfs objects, what we can do is
the binary takes the default, patches it with user's and uses that.
HOCON as a superset of JSON designed to be configuration language would be awesome but it looks like there is no implementation for Go.
When the default config is updated (e.g. protocols or bootstrap peers are added), users need to update their
~/.ipfs/config
manually.Many programs solve the issue by only writing settings that were actually modified into the file, falling back to built-in defaults for settings that are not present when reading.
To see the full config, users are able to run
ipfs config show
.Some additonal options for storing a default config for the user to read, each one having some advantages and disadvantages:
Swarm_default
,Bootstrap_default
and ignore them when reading.config.defaults
file dumping all the default settings.ipfs config show --defaults
instead.Finally, it would be nice to have an
ipfs config
subcommand that resets a setting to the default value, removing it from the config file.