From 873d131cc9f554ecc6078e637f7a2f73b1e777e1 Mon Sep 17 00:00:00 2001 From: Nicholas O'Connor Date: Fri, 14 Apr 2017 22:39:31 -0700 Subject: [PATCH] that's what i get for using commit -a --- src/config/defaults.cpp.cog | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 src/config/defaults.cpp.cog diff --git a/src/config/defaults.cpp.cog b/src/config/defaults.cpp.cog new file mode 100644 index 0000000..36e77c3 --- /dev/null +++ b/src/config/defaults.cpp.cog @@ -0,0 +1,28 @@ +// vim: ft=cpp : + +#include "json.hpp" + +#include "config.hpp" + +using namespace std; +using nlohmann::json; + +json cellar::config::get_default_config() { + json result; +/*[[[cog + import cog + import configparser + + cparse = configparser.ConfigParser() + cparse.read("cogrc") + config = cparse["defaults"] + for key in config.keys(): # TODO: bug #26 + value = config[key] + print(" -- Compiling in default value for {0}: {1}".format(key, value)) + cog.outl("result[\"{0}\"] = \"{1}\";".format(key, value)) +]]]*/ +//[[[end]]] + return result; +} + +