Skip to content

StringSlice question #910

@oleorhagen

Description

@oleorhagen

Hi

This is more of a question than an issue, but I was curious.

So if you have a StringSlice flag, say f1, then the expected behaviour from my side would be:

-f a b c -> []string{"a", "b", "c"}

However, the result is:
-f a b c -> []string{"a"}
and b and c is simply ignored.

It does work if you quote the strings though:
-f "a b c -> []string{"a", "b", "c"}

Is this expected behaviour?

cli version: b67dcf995b6a7b7f14fad5fcb7cc5441b05e814b (1.19.1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions