Live data from Hacker News

Facebook PathPicker

facebook.github.io

11–20 of 168 posts

Re: Facebook PathPicker

#11

I use fzf[0] for similar purposes. [0] https://github.com/junegunn/fzf

Yeah fzf is great -- there are a few differences since PathPicker can execute any command with the selected file(s) (rather than just write it to stdout) and runs in tmux with no issues, but fzf has great vim integration and I believe actually verifies the file matches. Glad more people are working in the productivity space though!

I haven't really had issues with fzf in tmux. Personally I just write a couple of my own aliases on top of fzf and it works great. I have ^T bound to open fzf and then edit the file I pick in vim. For me I find that editing files and selecting files to add to my VCS are my two uses cases. The latter I solve with scm_breeze[0].

[0] https://github.com/ndbroadbent/scm_breeze

Re: Facebook PathPicker

#12

Hey everyone, I'm in the main engineer on this project if anyone has questions. Facebook has a large codebase, so naturally we have a lot of long filenames and paths. It's a pain to type these out by hand, so I'd see a lot of (new) engineers select the text with their mouse before pasting it into the command line. This is pretty inefficient and I knew there had to be a better way, so a few of us started hacking on a…

Oh wow, thanks! I was just thinking about this today - how I'm always cut-and-pasting file paths from ag (silver surfer) results at the console.

One thing I noticed: FPP gets confused by filenames with multiple dots. If a file is named for example "dev_backup.ldif.gz", FPP thinks that "ldif.gz" is the entire file name.

Re: Facebook PathPicker

#13
Looks nice. Is it better than the built-in "arrow-keys-browseable" menu completion of zsh? (Random "screenshot" available at http://www.masterzen.fr/2009/04/19/in-love-with-zsh-part-one... under "Menu selection")

I've always been wanting an integrated file picker on unix that was as efficient as the ones in the venerable 4DOS (and 4NT) shells.

Re: Facebook PathPicker

#14

Hey everyone, I'm in the main engineer on this project if anyone has questions. Facebook has a large codebase, so naturally we have a lot of long filenames and paths. It's a pain to type these out by hand, so I'd see a lot of (new) engineers select the text with their mouse before pasting it into the command line. This is pretty inefficient and I knew there had to be a better way, so a few of us started hacking on a…

Dude, this is awesome. I've often thought about making a tool that does exactly this, but put it on the back burner of my mind. Really cool to see someone else had the same idea, but went a step further to actually execute it :)

Re: Facebook PathPicker

#15

Hey everyone, I'm in the main engineer on this project if anyone has questions. Facebook has a large codebase, so naturally we have a lot of long filenames and paths. It's a pain to type these out by hand, so I'd see a lot of (new) engineers select the text with their mouse before pasting it into the command line. This is pretty inefficient and I knew there had to be a better way, so a few of us started hacking on a…

[deleted]

Re: Facebook PathPicker

#16
post #9

Hey everyone, I'm in the main engineer on this project if anyone has questions. Facebook has a large codebase, so naturally we have a lot of long filenames and paths. It's a pain to type these out by hand, so I'd see a lot of (new) engineers select the text with their mouse before pasting it into the command line. This is pretty inefficient and I knew there had to be a better way, so a few of us started hacking on a…

do we need to open any specific mode in terminal for FPP?

Don't think so itsbits -- we strip out color codes and it works just fine inside tmux, but let us know if you have any issues on GitHub!

Re: Facebook PathPicker

#17
post #6

Hey everyone, I'm in the main engineer on this project if anyone has questions. Facebook has a large codebase, so naturally we have a lot of long filenames and paths. It's a pain to type these out by hand, so I'd see a lot of (new) engineers select the text with their mouse before pasting it into the command line. This is pretty inefficient and I knew there had to be a better way, so a few of us started hacking on a…

Good work! when I was at FB I rolled my own, called "gitsh": https://gist.github.com/aristus/2304335 One of the most useful features is range selection syntax, eg, run git rm on items 4-16.

Ah yes I remember this! I was always bad at typing out the numbers though. We support range selection as well, but it does require a keypress for each (which is less than ideal if you have a ton of entries).

Maybe we'll integrate some kind of line-number-selection-mode one day!

Post reply on HN