diff options
author | Jakob P. Liljenberg <admin@qvantnet.com> | 2024-02-11 16:46:44 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-11 16:46:44 +0100 |
commit | c587c9f1e3ceff0f028bb7937bf51234cfeb2949 (patch) | |
tree | 0f54dfb3303da66154076f727036add1e503cc9a | |
parent | 77c758c3492c0435aa2427aaef3e6b6139c6c9f6 (diff) | |
parent | c7fdd8adfee34bfe728cf7f809f8fcd8472e14d0 (diff) |
Merge pull request #743 from planet36/config-trailing-newline
-rw-r--r-- | src/btop_config.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/btop_config.cpp b/src/btop_config.cpp index 0b44630..aa4d813 100644 --- a/src/btop_config.cpp +++ b/src/btop_config.cpp @@ -732,9 +732,9 @@ namespace Config { if (geteuid() != Global::real_uid and seteuid(Global::real_uid) != 0) return; std::ofstream cwrite(conf_file, std::ios::trunc); if (cwrite.good()) { - cwrite << "#? Config file for btop v. " << Global::Version; + cwrite << "#? Config file for btop v. " << Global::Version << "\n"; for (auto [name, description] : descriptions) { - cwrite << "\n\n" << (description.empty() ? "" : description + "\n") + cwrite << "\n" << (description.empty() ? "" : description + "\n") << name << " = "; if (strings.contains(name)) cwrite << "\"" << strings.at(name) << "\""; @@ -742,6 +742,7 @@ namespace Config { cwrite << ints.at(name); else if (bools.contains(name)) cwrite << (bools.at(name) ? "True" : "False"); + cwrite << "\n"; } } } |