CLI interface to medialist (fossil mirror)
修訂 | 1c64406f682510d8755871cc68d7c619167713c5 (tree) |
---|---|
時間 | 2021-02-20 10:40:03 |
作者 | stigma@disroot.org <stigma@disr...> |
Commiter | stigma@disroot.org |
fix: check for both "general" and "lists"
The "medialist" page used "general" as that was the intended
key, but I forgot to actually update it in the source.
FossilOrigin-Name: fbcfaa4e20896f959048298fec6b67a838213ce8fb580412a5517dc5b8ffb716
@@ -53,7 +53,11 @@ main(string[] args) | ||
53 | 53 | |
54 | 54 | ConfigParser parser = new ConfigParser(); |
55 | 55 | parser.read(buildPath(config_dir, "medialist.conf")); |
56 | - if (parser.hasOption("Lists", "directory")) { | |
56 | + | |
57 | + if (parser.hasOption("general", "directory")) { | |
58 | + data_dir = parser.get("general", "directory"); | |
59 | + } else if (parser.hasOption("Lists", "directory")) { | |
60 | + /* XXX: compat for early versions. no need to remove. */ | |
57 | 61 | data_dir = parser.get("Lists", "directory").expandTilde; |
58 | 62 | } |
59 | 63 | parser.destroy(); |