mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-29 00:03:58 +01:00
JsonConfig: write all flags when generating config file
This commit is contained in:
@@ -147,15 +147,11 @@ void ffParseCPUJsonObject(FFCPUOptions* options, yyjson_val* module)
|
||||
|
||||
void ffGenerateCPUJsonConfig(FFCPUOptions* options, yyjson_mut_doc* doc, yyjson_mut_val* module)
|
||||
{
|
||||
__attribute__((__cleanup__(ffDestroyCPUOptions))) FFCPUOptions defaultOptions;
|
||||
ffInitCPUOptions(&defaultOptions);
|
||||
ffJsonConfigGenerateModuleArgsConfig(doc, module, &options->moduleArgs);
|
||||
|
||||
ffJsonConfigGenerateModuleArgsConfig(doc, module, &defaultOptions.moduleArgs, &options->moduleArgs);
|
||||
ffTempsGenerateJsonConfig(doc, module, options->temp, options->tempConfig);
|
||||
|
||||
ffTempsGenerateJsonConfig(doc, module, defaultOptions.temp, defaultOptions.tempConfig, options->temp, options->tempConfig);
|
||||
|
||||
if (defaultOptions.showPeCoreCount != options->showPeCoreCount)
|
||||
yyjson_mut_obj_add_bool(doc, module, "showPeCoreCount", options->showPeCoreCount);
|
||||
yyjson_mut_obj_add_bool(doc, module, "showPeCoreCount", options->showPeCoreCount);
|
||||
}
|
||||
|
||||
void ffGenerateCPUJsonResult(FFCPUOptions* options, yyjson_mut_doc* doc, yyjson_mut_val* module)
|
||||
|
||||
Reference in New Issue
Block a user