diff --git a/main.go b/main.go index be2e329..815de64 100644 --- a/main.go +++ b/main.go @@ -23,11 +23,11 @@ var ( picker = app.Command("pick", "Pick an item from clipboard history") maxPicker = picker.Flag("max-items", "scrollview length").Default("15").Int() - pickTool = picker.Flag("tool", "Which selector to use: dmenu/rofi/-").Default("dmenu").String() + pickTool = picker.Flag("tool", "Which selector to use: dmenu/rofi/STDOUT").Short('t').Default("dmenu").String() clearer = app.Command("clear", "Remove item(s) from history") maxClearer = clearer.Flag("max-items", "scrollview length").Default("15").Int() - clearTool = clearer.Flag("tool", "Which selector to use: dmenu/rofi/-").Default("dmenu").String() + clearTool = clearer.Flag("tool", "Which selector to use: dmenu/rofi/STDOUT").Short('t').Default("dmenu").String() clearAll = clearer.Flag("all", "Remove all items").Short('a').Default("false").Bool() ) diff --git a/selector.go b/selector.go index 54d6d09..9f18f4f 100644 --- a/selector.go +++ b/selector.go @@ -15,7 +15,7 @@ func selector(data []string, max int, tool string) (string, error) { } // output to stdout and return - if tool == "-" { + if tool == "STDOUT" { escaped, _ := preprocessData(data, false) os.Stdout.WriteString(strings.Join(escaped, "\n")) return "", nil