simonw / datasette

An open source multi-tool for exploring and publishing data
https://datasette.io
Apache License 2.0
9.54k stars 687 forks source link

`--settings settings.json` option #2087

Open simonw opened 1 year ago

simonw commented 1 year ago

https://discord.com/channels/823971286308356157/823971286941302908/1120705940728066080

May I add a request to the whole metadata / settings ? Allow to pass --settings path/to/settings.json instead of having to rely exclusively on directory mode to centralize settings (this would reflect the behavior of providing metadata)

asg017 commented 1 year ago

I just saw in the docs that Dasette auto-detects settings.json:

settings.json - settings that would normally be passed using --setting - here they should be stored as a JSON object of key/value pairs Source

adarshp commented 1 year ago

@asg017 - the docs say that the autodetection only occurs in configuration directory mode. I for one would also be interested in the --settings settings.json feature.

For context, I am developing a large database for use with Datasette, but the database lives in a different network volume than my source code, since the volume in which my source code lives is aggressively backed up, while the location where the database lives is meant for temporary files and is not as aggressively backed up (since the backups would get unreasonably large).