Skip to content

Format-specific CLI options #28

@alvinreal

Description

@alvinreal

Description

Add format-specific flags to the CLI.

Options

  • --csv-delimiter <char> (default: comma)
  • --csv-no-header (input has no header row)
  • --csv-header <fields> (explicit headers)
  • --xml-root <name> (root element name for output)
  • --xml-attr-prefix <prefix> (default: @)
  • --yaml-multi (treat as multi-document)

TDD Tests

  • --csv-delimiter "\t" reads TSV correctly
  • --csv-no-header returns array of arrays
  • --csv-header "a,b,c" overrides detected headers
  • --xml-root items wraps output in <items>
  • --xml-attr-prefix _ uses _id instead of @id
  • --yaml-multi reads --- separated docs
  • Options only apply to relevant formats (no error if unused)

Part of #4

Metadata

Metadata

Assignees

No one assigned

    Labels

    formatFormat reader/writertestingTesting infrastructurev0.4.0Milestone: v0.4.0 Extended Formats

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions