Skip to content
iandolPublic
forked from TD-Sky/sudo.yazi

About

Call sudo in yazi; forked to use Python or Ruby

Topics

Resources

Stars

7 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

26 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sudo.yazi

Call sudo in yazi. This fork replaces the NuShell dependency in the original https://github.com/TD-Sky/sudo.yazi with Ruby or Python which are more commonly installed. Made using Gemini CLI.

Installation

$ ya pack -a iandol/sudo

Requirements

Functions

  • copy files
  • move files
  • rename file
  • trash files
  • remove files
  • create absolute-path symbolic links
  • create relative-path symbolic links
  • create hard links
  • touch new file
  • make new directory
  • change files' mode bits

You can use conceal to browse and restore trashed files

Usage

Here are my own keymap for reference only:

# sudo cp/mv
[[mgr.prepend_keymap]]
on = ["R", "p", "p"]
run = "plugin sudo -- paste"
desc = "sudo paste"

# sudo cp/mv --force
[[mgr.prepend_keymap]]
on = ["R", "P"]
run = "plugin sudo -- paste --force"
desc = "sudo paste"

# sudo mv
[[mgr.prepend_keymap]]
on = ["R", "r"]
run = "plugin sudo -- rename"
desc = "sudo rename"

# sudo ln -s (absolute-path)
[[mgr.prepend_keymap]]
on = ["R", "p", "l"]
run = "plugin sudo -- link"
desc = "sudo link"

# sudo ln -s (relative-path)
[[mgr.prepend_keymap]]
on = ["R", "p", "r"]
run = "plugin sudo -- link --relative"
desc = "sudo link relative path"

# sudo ln
[[mgr.prepend_keymap]]
on = ["R", "p", "L"]
run = "plugin sudo -- hardlink"
desc = "sudo hardlink"

# sudo touch/mkdir
[[mgr.prepend_keymap]]
on = ["R", "a"]
run = "plugin sudo -- create"
desc = "sudo create"

# sudo trash
[[mgr.prepend_keymap]]
on = ["R", "d"]
run = "plugin sudo -- remove"
desc = "sudo trash"

# sudo delete
[[mgr.prepend_keymap]]
on = ["R", "D"]
run = "plugin sudo -- remove --permanently"
desc = "sudo delete"

# sudo chmod
[[mgr.prepend_keymap]]
on = ["R", "m"]
run = "plugin sudo -- chmod"
desc = "sudo chmod"

About

Call sudo in yazi; forked to use Python or Ruby

Topics

Resources

Stars

7 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages