diff options
author | midipix <writeonce@midipix.org> | 2025-06-11 06:06:51 +0000 |
---|---|---|
committer | midipix <writeonce@midipix.org> | 2025-06-11 06:08:05 +0000 |
commit | 2115d01c6543b2ab46b0205287882fc4704d1832 (patch) | |
tree | 89c1330bc9b26796316cee527544391c65f24242 /src/driver | |
parent | 0044bcd283400d4e68b340d9d5aac62f775e677d (diff) | |
download | perk-2115d01c6543b2ab46b0205287882fc4704d1832.tar.bz2 perk-2115d01c6543b2ab46b0205287882fc4704d1832.tar.xz |
driver: added the --yaml switch (same as --pretty=yaml).
Diffstat (limited to 'src/driver')
-rw-r--r-- | src/driver/pe_driver_ctx.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/driver/pe_driver_ctx.c b/src/driver/pe_driver_ctx.c index 5e2f8ee..279527d 100644 --- a/src/driver/pe_driver_ctx.c +++ b/src/driver/pe_driver_ctx.c @@ -191,6 +191,7 @@ static int pe_cctx_update( const char * cmdarg) { struct argv_entry * entry; + struct argv_entry * fmtarg; const char * pretty; pretty = 0; @@ -221,6 +222,10 @@ static int pe_cctx_update( cctx->drvflags |= PERK_DRIVER_VERSION; break; + case TAG_YAML: + fmtarg = entry; + break; + case TAG_PRETTY: pretty = entry->arg; break; @@ -327,6 +332,9 @@ static int pe_cctx_update( } else if (pretty && !strcmp(pretty,"dlltool")) { cctx->fmtflags |= PERK_PRETTY_DLLTOOL; + + } else if (fmtarg && (fmtarg->tag == TAG_YAML)) { + cctx->fmtflags |= PERK_PRETTY_YAML; } return 0; |