mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
did some cleanup
This commit is contained in:
parent
b0800bbe73
commit
670cfb3647
3 changed files with 1 additions and 4 deletions
|
|
@ -35,7 +35,6 @@ tokio-util = "0.7.10"
|
|||
tracing = { version = "0.1.40", features = [ "max_level_debug", "release_max_level_warn" ] }
|
||||
tracing-appender = "0.2.3"
|
||||
tracing-subscriber = "0.3.18"
|
||||
nix = "0.28.0"
|
||||
|
||||
[target."cfg(unix)".dependencies]
|
||||
libc = "0.2.153"
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ function Folder:linemode(area, files)
|
|||
elseif mode == "permissions" then
|
||||
spans[#spans + 1] = ui.Span(f.cha:permissions() or "")
|
||||
elseif mode == "owner" then
|
||||
spans[#spans + 1] = ui.Span(f.cha.owner or "it failed")
|
||||
spans[#spans + 1] = ui.Span(f.cha.owner or "")
|
||||
end
|
||||
|
||||
spans[#spans + 1] = ui.Span(" ")
|
||||
|
|
|
|||
|
|
@ -84,9 +84,7 @@ impl From<Metadata> for Cha {
|
|||
},
|
||||
#[cfg(unix)]
|
||||
owner: {
|
||||
//use nix::unistd::User;
|
||||
use std::os::unix::fs::MetadataExt;
|
||||
//from_uid(m.uid()).
|
||||
users::get_user_by_uid(m.uid()).unwrap().name().to_str().unwrap_or_default().to_string()
|
||||
+ " " + users::get_group_by_gid(m.gid()).unwrap().name().to_str().unwrap_or_default()
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue