Including the config file example in the root of the build output can suggest that editing it will have an effect on the running program. In fact, it does not - it has to be moved to the datadir to be loaded. By moving it into share/examples/, its status as an example is clear.
build: include example bitcoin.conf in build outputs under share/examples/ subdirectory #25935
pull luke-jr wants to merge 1 commits into bitcoin:master from luke-jr:dist_bitcoinconf_as_example changing 2 files +3 −3-
luke-jr commented at 1:00 AM on August 26, 2022: member
-
af83a0e33d
build: include example bitcoin.conf in build outputs under share/examples/ subdirectory
Including the config file example in the root of the build output can suggest that editing it will have an effect on the running program. In fact, it does not - it has to be moved to the datadir to be loaded. By moving it into share/examples/, its status as an example is clear.
-
luke-jr commented at 1:01 AM on August 26, 2022: member
Actually, upon further thought, any objection to having it installed with the rest of the docs?
-
ghost commented at 1:28 AM on August 26, 2022: none
TBH newbies have no clue or even check these docs for example bitcoin.conf no matter which directory it exists in. Docs are for users who already know a few things about Bitcoin Core, however they won't need example conf files.
An empty or basic bitcoin.conf should be created when bitcoind runs for the first time.
I have been using bitcoin core for a few years now, still did not read all docs.
- DrahtBot added the label Build system on Aug 26, 2022
-
DrahtBot commented at 9:18 AM on September 23, 2022: contributor
<!--e57a25ab6845829454e8d69fc972939a-->
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
<!--021abf342d371248e50ceaed478a90ca-->
Reviews
See the guideline for information on the review process. A summary of reviews will appear here.
<!--174a7506f384e20aa4161008e828411d-->
Conflicts
No conflicts as of last run.
- achow101 requested review from theuni on Apr 25, 2023
- achow101 requested review from josibake on Apr 25, 2023
-
josibake commented at 12:07 PM on May 1, 2023: member
Including the config file example in the root of the build output can suggest that editing it will have an effect on the running program.
I don't think this is true, and it is pretty clear in the documentation in the repo that you must move the config file to the datadir. For example, the file itself starts with:
## ## bitcoin.conf configuration file. ## Generated by contrib/devtools/gen-bitcoin-conf.sh. ## ## Lines beginning with # are comments. ## All possible configuration options are provided. To use, copy this file ## to your data directory (default or specified by -datadir), uncomment ## options you would like to change, and save the file. ##By moving it into share/examples/, its status as an example is clear.
Technically, this file isn't an example, but a fully commented-out config file. Back when I wrote the script, the old config file was an example, and I didn't think that hard about it (which is why the script generates the file in
share/examples), but I think for the release/build outputs it's more correct to have it in the root directory to 1) make it easier for the user to find it and 2) be clear that it is not an example config but a full config -
fanquake commented at 8:52 AM on May 3, 2023: member
Given the above, going to close this for now.
- fanquake closed this on May 3, 2023
- bitcoin locked this on May 2, 2024