Replies: 2 comments 6 replies
-
I've written a small script that tries to do something very similar to what you're describing here. Maybe this is helpful. My solution uses fzf's "Field Index Expressions" to pull this off (see To solve your particular problem, you could try to sanitize cat yourfile.txt | fzf --multi --reverse | cut -d '|' -f 2 | xargs firefox |
Beta Was this translation helpful? Give feedback.
-
Thanks @hamvocke and @LangLangBart. Both of the solutions work but I also need this:
Apart from this, I do not know if there is any shortcut to select all the input in the search bar of fzf (like ctrl+a). Any idea? |
Beta Was this translation helpful? Give feedback.
-
I am using this to open urls from a file in the browser
grep -n '' "filename" | fzf -m --reverse | xargs -d '\n' firefox
It works well when I only have the url in a line. The problem is that in that file I have the url with more text. I use it for bookmarks and it looks like this per line:
"Bookmark Name" | https://github.com/junegunn/fzf/ | +tag1 +tag2 | [Description-optional]
What I want is to open only the url and not the entire line in the browser. I have searched before posting this, so help would be appreciated.
Beta Was this translation helpful? Give feedback.
All reactions