Lf: How To Turn It Into A Really Powerful File Manager

  Рет қаралды 29,139

Brodie Robertson

Brodie Robertson

Күн бұрын

Пікірлер: 56
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
What programs do you make use of with your terminal file manager, it doesn't have to be lf. Let me know down below.
@med5032
@med5032 4 жыл бұрын
2:24 use Jaro for that github.com/isamert/jaro#term My dotfiles: github.com/aliveupstairs/dotfiles/blob/master/.config/associations
@med5032
@med5032 4 жыл бұрын
3:38 (2 ways to define commands comment) They're are actually four. $ shell shell command % shell-pipe shell command running with the ui ! shell-wait shell command waiting for key press & shell-async shell command running asynchronously
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
@@med5032 oh I didn't realise there were 2 others
@med5032
@med5032 4 жыл бұрын
5:58 to change the color for executables, you define a file, say ~/.config/LS_COLORS, add EXEC 38;5;107;1 to it, run dircolor ~/.config/LS_COLORS and it will change in that session. I prefer to have this line in my .profile file to do this only once on startup: eval "$(dircolors $HOME/.config/LS_COLORS)" My LS_COLORS: github.com/aliveupstairs/dotfiles/blob/ce5ad8abe620cd6233b2a1998de6f6777faee4a6/.config/LS_COLORS#L16
@med5032
@med5032 4 жыл бұрын
For unarchiving, I just use unar theunarchiver.com (it's pretty good) for all of the types and rely on xdg-open (Jaro) to do the unarchiving. I should add refreshing lf after cmd open. Another note is that if you're going to use a key to call a cmd, just define the command in map directly (see my lfrc). I only use cmd when I don't want a keybinding. My lfrc: github.com/aliveupstairs/dotfiles/blob/master/.config/lf/lfrc#L50
@VeitLehmann
@VeitLehmann 10 ай бұрын
Wow, lf is really neat! Perfect if you already have your CLI setup nicely and want to build from there so it integrates seamlessly. Also, it's sooo much faster and leaner than ranger! I didn't know any of those file managers, only knew mc until now. Now I quickly tested ranger, lf, nnn, vifm, and mc again (haven't used it for years), and my favorites are clearly lf and ranger. But because of the speed advantage, lf has the edge and I'll look deeper into it. I'll keep ranger installed for inspiration.
@mysteriouslymysteriousmyst9139
@mysteriouslymysteriousmyst9139 3 жыл бұрын
Just installed it and I like it so far.
@bobkoss280
@bobkoss280 4 жыл бұрын
Offtopic - how did you comment/uncomment multiple lines in nvim? Great video. Very informative.
@xasthul2355
@xasthul2355 Жыл бұрын
Thank you for video! Is it possible to bind a key to open lf? I tried to do it with sxhkd and key bindings of my window manager (awesome), but it didn’t work
@alejodelosreyes6277
@alejodelosreyes6277 3 жыл бұрын
how did you got to have lines between the panels?
@jobaizen4892
@jobaizen4892 9 ай бұрын
Hey bro how i can set nvim default text editor when im opening txt file in fl?
@danieldiaz2093
@danieldiaz2093 Жыл бұрын
Great! very clear and very good configuration. Can you compress files?
@hoangtu06081991
@hoangtu06081991 2 жыл бұрын
so touching for an excellent video
@humm535
@humm535 4 жыл бұрын
I tried lf and I think it’s a great program-I just don’t see why you would use it. I’m happy with typical shell commands. Have you actually read the docs of lf? If not-take a few minutes and `lf -doc | $PAGER`.
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
Its generally going to be quicker especially with actions across directories, if you don't want to use it that's up to you.
@xllvr
@xllvr 4 жыл бұрын
Been using lf under your recommendations and been having a great experience. This was a blessing as well. Is it possible to do the wallpaper command with sxiv?
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
No but if you don't want to have feh installed you can replace it with nitrogen, which is just a wallpaper setter
@xllvr
@xllvr 4 жыл бұрын
I see. Thanks for the reply!
@edvonrattlehead2135
@edvonrattlehead2135 4 жыл бұрын
unsurprisingly enough luke already automated a way to set a wallaper without either feh nor nitrogen, here's the scrip github.com/LukeSmithxyz/voidrice/blob/master/.local/bin/setbg you can call it from sxiv or from pretty much any file manager.
@soulofhogwarts
@soulofhogwarts 4 жыл бұрын
how can I make new folder or file using lf? And also in st how can you scroll up for seeing long output? Also I thought lf has integrated shell which come up after pressing enter but typing any command nothing do much.
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
By default lf is a glorified ls you need to add that behaviour in yourself. In st you need to add the scrollback patch to scrollback or use a multiplexer like tmux. I'm not sure about that shell binding I've either removed it or never bothered using it but you could easily bind it yourself.
@soulofhogwarts
@soulofhogwarts 4 жыл бұрын
@@BrodieRobertson Thanks for replying.
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
@@soulofhogwarts if you check out my lfrc you should get a pretty clear idea to do the binding plus I've got file and folder creation working.
@imeguras6402
@imeguras6402 3 жыл бұрын
there's an error on the open command, it should be video/*|image/*|application/pdf not video/*|image/*/application/pdf
@LawrenceHe
@LawrenceHe 4 жыл бұрын
How do I open SC-IM files in LF? I tried adding *.sc) scim $f;; to my open commands in lfrc but it doesn't work
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
Is it being caught by a more general case before it gets to that point.
@LawrenceHe
@LawrenceHe 4 жыл бұрын
@@BrodieRobertson yeah I had the more general text/*) before it so it opened with vim, but I swapped it to put it before that first and it still doesn't seem to work. Here's how I have it now cmd open ${{
@LawrenceHe
@LawrenceHe 4 жыл бұрын
case $(file --mime-type $f -b) in *.sc) scim $f;; text/*) $EDITOR $fx;; *) open $f & ;; esac
@lionwolf
@lionwolf 3 жыл бұрын
Thank you for tutorial. Have same questions about lf. Is it any opportunity to bind keys for: 1) copy full path of current file (multiple files) to clipboard, 2) copy short path of current file (multiple files) to clipboard, 3) copy name of current file (multiple files) to clipboard, 4) open terminal in current lf directory? Can you help?
@ribosomerocker
@ribosomerocker 3 жыл бұрын
what do you mean by short path? for the first one, just bind a button to run this command `echo $f | xclip -sel clipboard`, $f is something that lf provides for us with the shell command interface, it's just the file's path. To fet the file's name, do `basename $f | xclip -sel clipboard`, which will copy it to your clipboard P.S.: The backticks (`) are there so signify commands, do not type them in
@Matthias19961
@Matthias19961 3 жыл бұрын
Is it possible to start lf always in a specific directory?
@BrodieRobertson
@BrodieRobertson 3 жыл бұрын
You could have lf automatically jump to a folder when you open it
@luteran42
@luteran42 4 жыл бұрын
i have set shell zsh set shellopts '-eu:--shwordsplit' in my lfrc and trash-cli working for me with spaces in file names.
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
The problem with that is it's not a very portable solution
@smccrode
@smccrode 4 жыл бұрын
Can you escape the space characters for trash CLI?
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
I tried it but I didn't couldn't get it working but that's probably me just being bad at scripting
@smccrode
@smccrode 4 жыл бұрын
Brodie Robertson darn. I figured you tried it. Did you use sed or something?
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
@@smccrode yeah that was the first thing that came to mind I'll have another crack at it, I could just have made a mistake
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
I ended up getting it working. The problem was that the for loop does not care about escaped spaces and was still breaking on them, but you can fix that with IFS=$' '
@m-k5526
@m-k5526 4 жыл бұрын
Can you preview an image file in lf?
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
I've heard that a few people have come up with ways to do it but out of the box no
@Yassinebridii
@Yassinebridii 3 жыл бұрын
I got it working, use this config, with the corresponding scripts in the folder: github.com/yassinebridi/.dotfiles/tree/master/lf/.config/lf And instead of running lf directly, run this script instead: github.com/yassinebridi/.dotfiles/blob/master/bin/bin/lfrun It needs python-ueberzug-git to be installed.
@hermannpaschulke1583
@hermannpaschulke1583 4 жыл бұрын
Who is this Trap Town xyz dude? Iv'e seen this channel in the comments of most of the youtubers I follow 🤔
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
A spam channel that reuploads trap music
@nomoredarts8918
@nomoredarts8918 Жыл бұрын
basically actually
@BrodieRobertson
@BrodieRobertson Жыл бұрын
true
@senninscorpion
@senninscorpion 4 жыл бұрын
Liked: Check Subscribed: Check Commented: Check A tip you could maybe use... I saw your compression choices, gz and bzip2, the good thing about both of them is that they are fast A while back I was looking into compression algorithms, XZ/LZMA2 are great compression algorithms, it wipes the floor with both .gz and bzip2 (specially if you use flags like -9 or -9e ... info available in the manpage), the sad thing is that it is slow. More recently I discovered one that is even better, ZStd, with the flags "--ultra -22" it compresses the files faster than xz and uncompresses WAY quicker. I haven't benchmarked xz and zstd but I managed to get amazing compression and even better speed with zstd. So you could add the tar cvJf for .tar.xz (J on tar is the parameter -6 on the xz algorithm) or create your own version of .tar.zst by piping ... `tar cf - * | zstd --compress --ultra --threads=0 -22 > NAME.tar.zst` Archlinux is using the zstd algorithm on the newer packages right now Now a question because I wasn't able to figure out ... Is it possible to have a "drag and drop" option in LF? Sometimes I'm sending a file to someone in a chat through the browser (or just uploading a file to a cloud storage) and a quicker way to do it would be to have in my clipboard to just "paste" into the upload. Keep up the awesome content Brodie! Your way of digging into stuff inspires me to learn more things as well!!!
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
I didn't pick those algorithms for any specific reason I just looked at what I commonly see on Linux but I'll check those out. You picked such a great time to ask about drag and drop in lf, come check out the newest video on the channel.
@dagda825
@dagda825 4 ай бұрын
Or just use ranger.
@user-qf2ti6jt9m
@user-qf2ti6jt9m 4 жыл бұрын
15:31 you could just `map tr $trash-restore` and also read `lf -doc` more carefully (see line 217)
@BrodieRobertson
@BrodieRobertson 4 жыл бұрын
I'm aware that I can do that
@dachd
@dachd 4 жыл бұрын
trash-cli is very sh!t, if you are also facing gvfs / filesystem unhadled crap with it, then you can use simple tool GIO with argument trash.
@dachd
@dachd 4 жыл бұрын
cmd trash %gio trash $fx
Compton: How To Enable Efficient Kawase Window Blur
14:25
Brodie Robertson
Рет қаралды 16 М.
NNN: Is This Terminal File Manager As Good As People Say?
22:23
Brodie Robertson
Рет қаралды 32 М.
This mother's baby is too unreliable.
00:13
FUNNY XIAOTING 666
Рет қаралды 39 МЛН
小蚂蚁会选到什么呢!#火影忍者 #佐助 #家庭
00:47
火影忍者一家
Рет қаралды 114 МЛН
ТИПИЧНОЕ ПОВЕДЕНИЕ МАМЫ
00:21
SIDELNIKOVVV
Рет қаралды 1,8 МЛН
Fzf: Can Do Far More Than Just Fuzzy Find Your Files
19:36
Brodie Robertson
Рет қаралды 18 М.
Rip Drag: Eliminate Your GUI File Manager Again!
9:03
Brodie Robertson
Рет қаралды 11 М.
Dragon: Eliminate The Need For All GUI File Managers!
16:01
Brodie Robertson
Рет қаралды 18 М.
My FAVORITE File Manager - Complete Midnight Commander Tutorial
22:32
Bash vs ZSH vs Fish: What's the Difference?
13:32
Eric Murphy
Рет қаралды 186 М.
vifm - The Terminal File Manager For The Vim-Centric User
24:07
DistroTube
Рет қаралды 76 М.
Everyone Is Switching To Linux
21:49
Brodie Robertson
Рет қаралды 96 М.
Turn Your Window Manager Into A Desktop Environment
16:47
DistroTube
Рет қаралды 141 М.
How to Set Up and Configure LF (The Best Terminal File Manager)
16:20
Harder Drive: Hard drives we didn't want or need
36:47
suckerpinch
Рет қаралды 1,7 МЛН