-
Notifications
You must be signed in to change notification settings - Fork 469
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Show mount points #1272
Comments
Does this mean it only works on Unix systems? I'm not sure if Windows has the concept of mount points. I think it should be implemented as a plugin rather than a builtin feature. Recently, I've been enhancing the API for extending UI components with plugins, #1257. This will make it easier to implement it as a UI plugin & fetcher. |
Yeah, I guess this would be Unix only. I'd be happy to have the feature as a plugin. |
I made a proof-of-concept plugin for this feature: https://github.com/Ape/mount-points.yazi However, it is currently quite unusable because of performance implications. The plugin refreshes the mount point information constantly. Ideally it would do it in a task and only when needed. |
@Ape there's a plugin archivemount.yazi, it can mount archives(as the name suggests) as well tell if a direc is a mountpoint or not. |
That plugin doesn't seem to currently have the feature I'm looking for. Check |
@Ape @sxyazi hey, mate ! how about this. I thing this will be a little bit better. function Status:name()
local h = self._tab.current.hovered
if not h then return ui.Line {} end
local mounted = io.popen("findmnt -n --output SOURCE,FSTYPE ".."'"..tostring(h.url).."'"):read("*a")
if mounted ~= "" then
mounted = " <- " .. mounted
return ui.Line(" " .. h.name .. mounted)
end
local linked = h.link_to
if linked ~= nil then
linked = " -> " .. tostring(linked)
return ui.Line(" " .. h.name .. linked)
end
end |
I am author of https://github.com/SL-RU/ranger_udisk_menu and recently switched to yazi. I in progress of implementing same functionality in yazi sxyazi 4rtemis-4rrow FYI related to #927 |
Please describe the problem you're trying to solve
I'd like to see if a directory is a mount point.
Would you be willing to contribute this feature?
Describe the solution you'd like
It could look something like this:
Additional context
No response
The text was updated successfully, but these errors were encountered: