Superfile – A fancy, pretty terminal file manager
github.com
github.com
brew install superfile
(ok)
superfile
(not found)
find superfile
(not sound)
cd /usr/local/Cellar/superfile/1.1.2/bin
ls
spf
This is mentioned in the tutorial but it's probably worth mentioning in the install section to save people 5-10 minutes of confusion. Once I found the filename I loved it.I encourage also supporting the author as well on their ko-fi page for a new laptop. (2)
I feel the market is ripe for a terminal ide again. Anything interesting going in in that space?
I’m really curious about this, not to derail the thread.
I think it should be the standard, but fact is most computer users are entertainment consumers and their computing devices are just a new and improved TV. It doesn't even occur to them to ask what's going on, hence the ubiquity of proprietary spyware. With TUIs and other nerdy stuff like that, the userbase is generally going to give a shit more, hence the higher standard.
Is excrate some new jargon meaning to take something out of a crate? Or just a boring typo for extract?
Looks nice. I dig the nerd font thing, I'd never used them because all of my TUI stuff is ncurses and the like, it's a nice thing to be able to do. I like the outline. I don't like a few things.
- Ctrl keys galore. I'm partial to vim keys, a lot of the keybinds on here are vim style, why not make it all of them?
- some of the defaults are weird or potentially dangerous. There's no confirmation for deletion for example, PageUp and PageDown don't work, cursor auto wraparound is a little confusing for something like this, and the cursor isn't a highlight, just a >.
- Bubbletea always seem to have a minimum terminal size which drives me nuts. Btop and other programs I've used have this problem.
All in all I like the ability to open multiple panes, the ability to open network drives, see ongoing/completed processes and see the clipboard. I find I virtually never need more than two panes though, and there are plenty of CLI utilities for FTP and stuff. I'm probably going to stick with an old school dual pane like vifm or MC. I'll keep this on my machine and test it out some more next time I need to connect to an ftp server or something, I like that it provides most of the functionality that graphical file managers like Nautilus have, I do miss some of that stuff in my terminal oriented environment, but not enough to go full mouse, so it's good to know I have an option that gives me some of both.
[1]: https://github.com/MHNightCat/superfile/issues/72 [2]: https://github.com/MHNightCat/superfile/releases/tag/v1.1.1
There's some stellar libraries in Go for terminal stuff, in particular anything from charmcli. They have an elm style TUI framework called bubbletea (which superfile uses), a styling library, prebuilt components, it's really incredible. I'm building a multiplayer tetris you can play through ssh, which is using bubbletea and another lib of theirs called wish.
they have a lot of stuff you can just use in regular shell stuff too: https://charm.sh
In fact, their license page makes it abundantly clear they are not open source:
> We own and reserve rights to our content, including text, images, and code in the app, which is protected by copyright and other laws.
I get this argument if a company or product claimed it was open source and it wasn’t, but it just doesn’t work if the product in question makes it quite clear they are not, or even leaves it ambiguous.
> And are you suggesting that people normally click the license page?
As my comment says, I am suggesting that they explicitly say they are not open source. It’s not like that’s featured front and center on literally any other product’s front page, so I’m not sure what exactly your expectations are here. Do you want them to have in 100pt font “WE ARE CLOSED SOURCE!!!” plastered across every page? Would that be enough?
I also sometimes use it as a pseudo IDE.
So there's one factor to cut the search-space in ~half :)
I'm recently trying out worker[0] and so far it's great.
Fortunately it's now on top of the to-do list: https://github.com/users/MHNightCat/projects/4/views/1
- power user workflows may differ from typical dev workflows. Imagine things that a point-and-click file manager solves quicker than the command-line. Example: manually organizing a bunch of .mp3s, or cleaning out misc downloads. A TUI file manager makes these tasks quicker too.
- quick directory navigation. cd is slow. There's solutions for a better cd, involving z or fzf or whatever. But a file manager should solve it too.
- a file manager, especially a two-pane view, is cognitively easier. Better UX. Example: Having a src/ pane on one side and dst/ on the other, selecting a few src/ files, then performing a copy command. You get instant visual feedback to confirm that the files appeared in dst/. Compared to ls, cp file1 file2 file3 dst/, ls dst/. I always feel the need to ls after commands because the command-line doesn't give much feedback.
tldr: speed, ux, comfort. But if you're already comfortable with your tools, I think that's the most important thing.
The way I do it is a bit nuts though, and you're right, the above is much more consistent and has its advantages
It's all about what you're used to and what you know. If you grew up in the age of the point-and-click GUI you might feel more comfortable using visual metaphors and stateful UIs for your intended actions. Others prefer to issue orders and have them obeyed without the song, dance, and lightshow.
Of course, issuing orders still has its advantages. And yes, growing up with GUIs makes a big difference.
I really like how minimalist yet extensible lf [0] is and just use edir [1] to rename files in bulk. Gluing them both together is really easy too.
Now guess what the executable is called…
EDIT: To be fair, right at the beginning of the tutorial is:
> First, if you want to open superfile by opening a terminal and typing spf.
pacman -Ql <package> | grep bin
There must be similar commands for other package managers.
I'm on Linux Mint 19
I think it's somewhat unreasonable to expect software released today will necessarily work on your environment without some legwork.
Issues with Linux binary distribution meanwhile are ubiquitous, with glibc probably being the single biggest offender. What's worse is that you can't even really statically link it without herculean effort. I've spent an inordinate amount of my life trying to wrangle third-party binaries on Linux libraries and it's just a sorry state of affairs.
Try taking a binary package from a vendor from even just 5 years ago and there's a non-zero chance it won't run on your modern distro.
> What's worse is that you can't even really statically link it without herculean effort.
The program we are discussing happens to be written in Go so it's trivial to build a statically linked executable.
With Go on Linux libc is only needed when the libc DNS resolver is used (instead of Go's built-in one) or if C libraries are used. superfile doesn't need either of these so it's very simple to build it as a pure Go executable which will be statically linked and contain no C code at all.
- any given release of a Linux distro will probably work on hardware released five years earlier -- one factor that reduces the cost of upgrading the OS (there are many more obvious factors)
- Microsoft is highly motivated to get customers to upgrade to the new Windows at the time. The legacy support is well-known as a "bone" (or: "a factor that reduces the cost of upgrading the OS")
- binary backwards/forwards compatibility is less of an issue in an environment that doesn't treat source code as a secret
- why run old versions of software? In other words: xterm is older than Windows and also as new as Windows
Also, I've always found it amusing that I have much less trouble running old windows software on a Linux (wine) than on new versions of windows.
You'll have to compile from source, or update your distro to a maintained version. Ubuntu 22.04 ships glibc 2.35, and so Mint 21 should work.
Mostly commenting because while this isn't really a tech support channel, being able to identify glibc version mismatch errors comes up extremely often, even in this day and age.
Where does it get installed? Will the user consent?
I did not use a Nerd Font until I tried superfile out today. It was not hard to build my own nerd font version of Berkeley Mono with font forge.
My first experience running a cool-looking TUI file manager yesterday (I actually ended up trying yazi first) was that I got a lot of blank squares in place of missing icons and emojis due to missing fonts. I had to spend 20 minutes figuring that out before I got a good experience.
Interestingly, I also tried wezterm[1] in the process. It actually ships with the required fonts as fallback, but the version from my distro's package manager didn't work (the AppImage did). I'm guessing my distro removed them, maybe for some of the reasons you cited. I started installing the nerd-fonts group for my distro. 6.5GB... no thanks. After manually poking through them and some googling I finally installed a couple and it's working now.
My overall point is that it's possible for app developers to provide good defaults like wezterm does. It's also possible for distro's to break those defaults. Also, if size is a concern then at least detect that I don't have a working font and offer to download one for me.
So the "best" it could do is bundle the font file, but then you would still have to configure your terminal to use it. At that point, it's easier to just tell you you need a nerd font and link to their repo.
That being said, I kind of agree that, since NerdFonts are pretty good and by now quite widespread, it wouldn't be a bad idea for major distros to patch their default monospace fonts so that you get NerdFonts out of the box in the default terminal.
But, in general, if you go out of your way to install a different terminal emulator, it's unlikely you'd have much trouble changing its font anyway; still, getting everything to look nice and pretty is sometimes harder, so I suppose wezterm is commendable for including fonts and colorschemes.
(The above really mostly applies to fonts as they are an additional dependency and also highly dependent on user preference. For pretty much everything else I agree that good defaults are under-emphasized in CLI/TUI utilities. Probably because options usually get added incrementally and breaking historical defaults is not a good idea.)
(Yes I know I could look it up but maybe this will spark a discussion)
And here's an example of ligatures (see the image on the right - you type what's on the left, and the right image is what shows in your editor): https://hilton.org.uk/blog/fira-code
I think but am not sure as I haven't looked in a while, that the folder and file icons are part of the nerdfonts as well, that regular fonts would just show as the generic "missing glyph" symbol.
Is there any technical reason the font can't be shipped in the binary and installed automatically?
- this is what a package manager is for
- installing the font/s (from the application?) would be a bit of a dick move and also presents a technical challenge (in other words: that's what a package manager is for)
- concerns about the efficiency of many applications all shipping duplicate assets (package manager again)
- concerns about distribution rights
- not all users will want to use the same font and this is an unsolvable problem -- do you ship: no fonts | one unwanted font | the user's preferred font that they already have installed plus all the other user's fonts
My first experience running a cool-looking TUI file manager yesterday (I actually ended up trying yazi first) was that I got a lot of blank squares in place of missing icons and emojis due to missing fonts. I had to spend 20 minutes figuring that out before I got a good experience.
Interestingly, I also tried wezterm[1] in the process. It actually ships with the required fonts as fallback, but the version from my distro's package manager didn't work (the AppImage did). I'm guessing my distro removed them, maybe for some of the reasons you cited. I started installing the nerd-fonts group for my distro. 6.5GB... no thanks. After manually poking through them and some googling I finally installed a couple and it's working now.
My overall point is that it's possible for app developers to provide good defaults like wezterm does. It's also possible for distro's to break those defaults.
> not all users will want to use the same font and this is an unsolvable problem -- do you ship: no fonts | one unwanted font | the user's preferred font that they already have installed plus all the other user's fonts
For me, I would absolutely prefer one unwanted font instead of losing those 20 minutes. If I don't like the font it ships with I should be able to override it. If size is a concern then don't ship the font, but detect that I don't have a working one and offer to download a default for me.
Absolutely, yes. No disagreement from me. I'm just guessing at why someone might choose not to for this particular case.
For example, you could write 'gum choose foo bar baz' to get a nice picker over the three provided options.
Their repo has a ton of examples: https://github.com/charmbracelet/gum
One that bites me a lot is when a vim keybinding is implemented, has insert mode, and they don't also rebind <C-w>. Go from trying to delete a word (backwards) but end up losing a whole session. It's such muscle memory I sometimes do it on webpages, but maybe that one is a feature instead of a bug lol
By contrast, in macOS all the window/UI keybindings are typically Cmd (Cmd-W) which means that GUI applications attempting to layer on vi keybindings don’t have to also audit all the Ctrl keybindings that might be doing something wildly different compared to what vi users expect.
Cmd for UI and Ctrl for terminal just makes for such a nice default convention.
So the Cmd/Ctrl split on Mac maps nicely to the Win/Ctrl split on Linux.
For the reasons you suggest (WMs often heavily using the super key), I would not want it to be used in the macOS way as I have a few dozen keybinds I'd lose or have to remap then. Stuff like focusing or moving windows or workspaces. Emacs can also make use of the super key, though I don't know if it has anything bound using it by default.
The macOS approach is cool and makes some sense, but I wouldn't want it forced on me, and I'm kinda glad I didn't imprint on it.
This is literally why Vim binding for Jupyter doesn't work for me and also why the "terminal" in Jupyter Lab is worse than not existing -- I can't help but press C-w
But it seems that this hotkey is not good for many people. It may be changed in the next version. Thanks for your feedback.
You can go to "~/.local/share/Trash" all files that you deleted are at there
But the good thing is they are just defaults. Hopefully there are already no legions of users resistant to any changes to defaults.
Error downloading theme: Get "https://github.com/MHNightCat/superfile/raw/main/themeZip/v1.1.2/theme.zip": dial tcp: lookup github.com on 8.8.8.8:53: dial udp 8.8.8.8:53: connect: network is unreachable1. Create a recursive symlink to itself: `ln -s test test`
2. open superfile and navigate to it.
3. Observe crash
Did the author say their product was better?
Of course. But that's not what he asked.
Heh, I ported mc to Apple's A/UX back in the early 90's!
If you're taking suggestions, making file copies use rsync under the hood would be great. I used to copy files over sshfs with ranger a lot and then found out the hard way that it was occasionally failing/being interrupted and then silently moving on in the transfer queue, so I had partial and corrupted video files it took months to notice. I do also use rsync for transfers a lot of the time, but sometimes you wanna move a bunch of files to different directories, and something like ranger is just faster and easier. Especially when you don't want everything from the source on the destination for space reasons, so can't just rsync whole dirs to grab the new stuff.