Some kind of shell is now there in act

This commit is contained in:
2022-08-24 00:29:26 +02:00
parent 2316a1125f
commit 50d11c0c62
8 changed files with 524 additions and 222 deletions

View File

@ -186,6 +186,20 @@ void cw_cfg_dump(cw_Cfg_t * cfg)
}
}
void cw_cfg_fdump(FILE *f, cw_Cfg_t * cfg)
{
mavliter_t it;
struct cw_Cfg_entry *e;
mavliter_init(&it, cfg->cfg);
mavliter_foreach(&it) {
e = mavliter_get(&it);
fprintf(f,"%s: '%s'\n", e->key, e->val);
}
}
struct parser {
int line;

View File

@ -56,6 +56,7 @@ int cw_cfg_base_exists_l(cw_Cfg_t ** cfgs, const char *key);
int cw_cfg_save(const char *filename, cw_Cfg_t *cfg, const char *format, ...);
uint16_t cw_cfg_get_word_l(cw_Cfg_t ** cfg, char *key, uint16_t def);
void cw_cfg_fdump(FILE *f, cw_Cfg_t * cfg);