Skip to content

cli: joining -I and -f- together does not work #2059

Closed

Description

@simonmichael

-I -f- or -f- -I work:

$ hledger print -f /dev/null | hledger -I -f- is --debug 8 2>&1 | grep probably
raw command is probably: "is"

By normal command line rules you'd expect -If- to also work, but hledger misparses it:

$ hledger print -f /dev/null | hledger -If- is --debug 8 2>&1 | grep probably
raw command is probably: ""

Related: https://hledger.org/faq.html#how-do-i-show-an-income-statement-restricted-to-just-my-credit-card-eg-

Activity

  1. added
    A-BUGSomething wrong, confusing or sub-standard in the software, docs, or user experience.
    cliCommand line parsing, options, arguments and suchlike.
    on Jul 8, 2023
  2. derelbenkoenig commented on Nov 14, 2023

    @derelbenkoenig

    That anchor tag seems to no longer exist in the faq page

  3. simonmichael commented on Nov 14, 2023

    @simonmichael
    MemberAuthor

    Sorry, I don't know the new anchor, but the link was unimportant, let's disregard it.

  4. added
    annoyance2-minorMinor to moderate usability/doc bug, reasonably easy to avoid or tolerate.
    affects3-fewAffects just a few users.
    on Dec 13, 2023
  5. simonmichael commented on Jun 16, 2025

    @simonmichael
    MemberAuthor

    A short flag with a value can't be combined with other short flags; this is now mentioned in the Options doc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-BUGSomething wrong, confusing or sub-standard in the software, docs, or user experience.affects3-fewAffects just a few users.annoyance2-minorMinor to moderate usability/doc bug, reasonably easy to avoid or tolerate.cliCommand line parsing, options, arguments and suchlike.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions