Re:Verb-Noun vs. Noun-Verb
by jodrellblank on Wednesday October 16, 2019 @06:58PM
(#21276944)
I don't recognise fzf as a tool, but is that better than
get-command *smb*
for fuzzy matching? Incidentally you can do get-command |% Name
To avoid having to write that {$_.} wrapping blob all the time, if you're merely expanding a property or calling a method on every object in the pipeline.fzf is https://github.com/junegunn/fzf, I prefer it over get-command smb because:
- it's fuzzy and more i.e. https://github.com/junegunn/fzf#search-syntax
- gives you a list which you can shrink further, again with fuzzy matching
- list can be navigated using keyboard, and then selected from
To avoid having to write that {$_.}
Heh, I actually didn't know that. Or forgot.
Re:Verb-Noun vs. Noun-Verb
by Ididntdothis on Wednesday October 16, 2019 @04:23PM
(#21275103)
”some seriously good options but it's those options which are hard to discover :)”
That’s modern UX for you. Hide features to the degree that only a lucky few will ever find them :). A lot of websites and mobile apps have adopted that philosophy.
Or do Ctrl-Enter to get the list of all matches and navigate with arrow keys, should be faster.
Thinking of it, I don't really need discoverability often but if I did I'd probably resort to
Get-Command | %{$_.Name} | fzf
bound to a key or so: this gives you fuzzy matching search of all possible commands. I just tried, 1683 commands in total and this got me all Smb commands in about the amount of time it took me to type 'SMb. It doesn't get better than that. Well, except that you could have fzf split the screen and show the help for each command there.
This is also the typical PS (or other shells for that matter) story: people complaining about not being able to do discoverability whle in fact the there are actually some seriously good options but it's those options which are hard to discover :)