aboutsummaryrefslogtreecommitdiff
path: root/spm.c
diff options
context:
space:
mode:
Diffstat (limited to 'spm.c')
-rw-r--r--spm.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/spm.c b/spm.c
index 3c18cf9..1cfc737 100644
--- a/spm.c
+++ b/spm.c
@@ -1191,6 +1191,15 @@ int install(const char *destroot, const char *_package) {
free(ucd);
}
+int init_config_global() {
+ SPM_GLOBAL.user_config_basedir = get_user_conf_dir();
+ SPM_GLOBAL.user_config_file = get_user_config_file();
+ SPM_GLOBAL.package_dir = realpath(PKG_DIR, NULL);
+ if (SPM_GLOBAL.user_config_file) {
+ config_read(SPM_GLOBAL.user_config_file);
+ }
+}
+
int main(int argc, char *argv[]) {
// not much to see here yet
// at the moment this will all be random tests, for better or worse