Unclear how to use relation-get when outside relation hooks

The output of relation-get --help includes:

relation-get prints the value of a unit’s relation setting, specified by key. If no key is given, or if the key is “-”, all keys and values will be printed.

While that’s mostly straightforward, the “if not key is given” bit definitely seems misleading, as the - is obviously required. It would be nice if that requirement were dropped and the tool would notice if you don’t specify a key and not assume that the unit name is the key.

1 Like