config: only create template file is prior was not found
parent
14b441be1e
commit
5462553741
|
|
@ -3509,13 +3509,13 @@ pub fn loadDefaultFiles(self: *Config, alloc: Allocator) !void {
|
|||
|
||||
// If both files are not found, then we create a template file.
|
||||
// For macOS, we only create the template file in the app support
|
||||
if (app_support_loaded and xdg_loaded) {
|
||||
if (!app_support_loaded and !xdg_loaded) {
|
||||
writeConfigTemplate(app_support_path) catch |err| {
|
||||
log.warn("error creating template config file err={}", .{err});
|
||||
};
|
||||
}
|
||||
} else {
|
||||
if (xdg_loaded) {
|
||||
if (!xdg_loaded) {
|
||||
writeConfigTemplate(xdg_path) catch |err| {
|
||||
log.warn("error creating template config file err={}", .{err});
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in New Issue