migrate to dotter
This commit is contained in:
parent
c5618f2f2c
commit
23b6c0a596
265 changed files with 62 additions and 3125 deletions
1
configs/yazi/init.lua
Normal file
1
configs/yazi/init.lua
Normal file
|
|
@ -0,0 +1 @@
|
|||
require("full-border"):setup()
|
||||
53
configs/yazi/keymap.toml
Normal file
53
configs/yazi/keymap.toml
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
# A TOML linter such as https://taplo.tamasfe.dev/ can use this schema to validate your config.
|
||||
# If you encounter any issues, please make an issue at https://github.com/yazi-rs/schemas.
|
||||
"$schema" = "https://yazi-rs.github.io/schemas/keymap.json"
|
||||
|
||||
[mgr]
|
||||
|
||||
prepend_keymap = [
|
||||
{ on = ["<Esc>"], run = "escape --all", desc = "Exit visual mode, clear selected, or cancel search" },
|
||||
|
||||
# Navigation
|
||||
{ on = ["h"], run = ["leave", "escape --visual --select"], desc = "Go back to the parent directory" },
|
||||
# { on = ["l"], run = ["enter", "escape --visual --select"], desc = "Enter the child directory" },
|
||||
{ on = ["l"], run = "plugin smart-enter", desc = "Enter the child directory, or open the file" },
|
||||
|
||||
{ on = ["<Left>"], run = ["leave", "escape --visual --select"], desc = "Go back to the parent directory" },
|
||||
{ on = ["<Right>"], run = ["enter", "escape --visual --select"], desc = "Enter the child directory" },
|
||||
|
||||
# Operation
|
||||
{ on = ["r"], run = "rename --empty=stem --cursor=start", desc = "Rename a file or directory" },
|
||||
{ on = ["R"], run = "rename --cursor=end", desc = "Rename a file or directory (keeping the current filename)" },
|
||||
|
||||
# Copy
|
||||
{ on = ["c", "c"], run = "copy path", desc = "Copy the absolute path" },
|
||||
{ on = ["c", "d"], run = "copy dirname", desc = "Copy the path of the parent directory" },
|
||||
{ on = ["c", "f"], run = "copy filename", desc = "Copy the name of the file" },
|
||||
{ on = ["c", "n"], run = "copy name_without_ext", desc = "Copy the name of the file without the extension" },
|
||||
{ on = ["c", "r"], run = "plugin rsync", desc = "Copy files using rsync" },
|
||||
|
||||
# Goto
|
||||
{ on = ["g", "h"], run = "cd ~", desc = "Go home" },
|
||||
{ on = ["g", "c"], run = "cd ~/.config", desc = "Goto ~/.config" },
|
||||
{ on = ["g", "d"], run = "cd ~/Downloads", desc = "Goto ~/Downloads" },
|
||||
{ on = ["g", "<Space>"], run = "cd --interactive", desc = "Jump interactively" },
|
||||
|
||||
# Goto
|
||||
{ on = ["g", "h"], run = "cd ~", desc = "Go to the home directory" },
|
||||
{ on = ["g", "c"], run = "cd ~/.config", desc = "Go to the config directory" },
|
||||
{ on = ["g", "d"], run = "cd ~/Downloads", desc = "Go to the downloads directory" },
|
||||
{ on = ["g", "t"], run = "cd /tmp", desc = "Go to the temporary directory" },
|
||||
{ on = ["g", "r"], run = "shell 'ya emit cd \"$(git rev-parse --show-toplevel)\"'", desc = "Go to git root" },
|
||||
{ on = ["g", "<Space>"], run = "cd --interactive", desc = "Go to a directory interactively" },
|
||||
|
||||
{ on = ["<C-x>", "j"], run = "shell 'ya pub-to 0 TransferDownload --list \"$@\"'", desc = "Download with transfer.nvim" },
|
||||
{ on = ["<C-x>", "k"], run = "shell 'ya pub-to 0 TransferUpload --list \"$@\"'", desc = "Upload with transfer.nvim" },
|
||||
{ on = ["<C-x>", "d"], run = ["shell 'ya pub-to 0 DiffRemote --orphan --list \"$@\"'", "quit"], desc = "Diff with transfer.nvim" },
|
||||
{ on = ["<C-x>", "<S-D>"], run = ["shell 'ya pub-to 0 TransferDirDiff --list \"$@\"'"], desc = "Diff directory with transfer.nvim" },
|
||||
]
|
||||
|
||||
[input]
|
||||
prepend_keymap = [{ on = ["<Esc>"], run = "close", desc = "Go back the normal mode, or cancel input" }]
|
||||
|
||||
[help]
|
||||
prepend_keymap = [{ on = "q", run = "escape", desc = "Clear the filter, or hide the help" }]
|
||||
19
configs/yazi/package.toml
Normal file
19
configs/yazi/package.toml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
[[plugin.deps]]
|
||||
use = "yazi-rs/plugins:full-border"
|
||||
rev = "1ab21d4"
|
||||
hash = "3996fc74044bc44144b323686f887e1"
|
||||
|
||||
[[plugin.deps]]
|
||||
use = "Ape/simple-status"
|
||||
rev = "d0da104"
|
||||
hash = "68603fdd1dcaf415227e2c77a9317947"
|
||||
|
||||
[[plugin.deps]]
|
||||
use = "yazi-rs/plugins:smart-enter"
|
||||
rev = "1ab21d4"
|
||||
hash = "56fdabc96fc1f4d53c96eb884b02a5be"
|
||||
|
||||
[[flavor.deps]]
|
||||
use = "yazi-rs/flavors:catppuccin-macchiato"
|
||||
rev = "d3fd3a5"
|
||||
hash = "e6c5beeb1da3199355734273ee452a7f"
|
||||
0
configs/yazi/plugins/.keep
Normal file
0
configs/yazi/plugins/.keep
Normal file
3
configs/yazi/theme.toml
Normal file
3
configs/yazi/theme.toml
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
[flavor]
|
||||
light = "catppuccin-macchiato"
|
||||
dark = "catppuccin-macchiato"
|
||||
183
configs/yazi/yazi.toml
Normal file
183
configs/yazi/yazi.toml
Normal file
|
|
@ -0,0 +1,183 @@
|
|||
# A TOML linter such as https://taplo.tamasfe.dev/ can use this schema to validate your config.
|
||||
# If you encounter any issues, please make an issue at https://github.com/yazi-rs/schemas.
|
||||
"$schema" = "https://yazi-rs.github.io/schemas/yazi.json"
|
||||
|
||||
[mgr]
|
||||
ratio = [1, 3, 4]
|
||||
sort_by = "alphabetical"
|
||||
sort_sensitive = false
|
||||
sort_reverse = false
|
||||
sort_dir_first = true
|
||||
linemode = "mtime"
|
||||
show_hidden = true
|
||||
show_symlink = true
|
||||
scrolloff = 5
|
||||
mouse_events = ["click", "scroll"]
|
||||
title_format = "Yazi: {cwd}"
|
||||
|
||||
[preview]
|
||||
cache_dir = ""
|
||||
image_delay = 0
|
||||
image_filter = "triangle"
|
||||
image_quality = 75
|
||||
max_height = 900
|
||||
max_width = 600
|
||||
sixel_fraction = 15
|
||||
tab_size = 2
|
||||
wrap = "no"
|
||||
|
||||
[opener]
|
||||
edit = [{ run = '[ -n "$EDITOR" ] && $EDITOR "$@"', desc = "$EDITOR", block = true, for = "unix" }, { run = 'code "%*"', orphan = true, for = "windows" }]
|
||||
open = [{ run = 'xdg-open "$@"', desc = "Open", for = "linux" }, { run = 'open "$@"', desc = "Open", for = "macos" }, { run = 'start "" "%1"', orphan = true, desc = "Open", for = "windows" }]
|
||||
reveal = [{ run = 'open -R "$1"', desc = "Reveal", for = "macos" }, { run = 'explorer /select, "%1"', orphan = true, desc = "Reveal", for = "windows" }, { run = '''exiftool "$1"; echo "Press enter to exit"; read''', block = true, desc = "Show EXIF", for = "unix" }]
|
||||
extract = [{ run = 'ya pub extract --list "$@"', desc = "Extract here", for = "unix" }, { run = 'ya pub extract --list %*', desc = "Extract here", for = "windows" }]
|
||||
play = [{ run = 'mpv "$@"', orphan = true, for = "unix" }, { run = 'mpv "%1"', orphan = true, for = "windows" }, { run = '''mediainfo "$1"; echo "Press enter to exit"; read''', block = true, desc = "Show media info", for = "unix" }]
|
||||
|
||||
[open]
|
||||
rules = [
|
||||
# Folder
|
||||
{ name = "*/", use = ["edit", "open", "reveal"] },
|
||||
|
||||
# Text
|
||||
{ mime = "text/*", use = ["edit", "reveal"] },
|
||||
|
||||
# Archive
|
||||
{ mime = "application/{,g}zip", use = ["extract", "reveal"] },
|
||||
{ mime = "application/x-{tar,bzip*,7z-compressed,xz,rar}", use = ["extract", "reveal"] },
|
||||
|
||||
# Image
|
||||
{ mime = "image/*", use = ["open", "reveal"] },
|
||||
|
||||
# Media
|
||||
{ mime = "{audio,video}/*", use = ["play", "open", "reveal"] },
|
||||
{ mime = "inode/x-empty", use = ["edit", "reveal"] },
|
||||
|
||||
# JSON
|
||||
{ mime = "application/json", use = ["edit", "reveal"] },
|
||||
{ mime = "*/javascript", use = ["edit", "reveal"] },
|
||||
|
||||
# Empty file
|
||||
{ mime = "inode/x-empty", use = ["edit", "reveal"] },
|
||||
|
||||
# Fallback
|
||||
{ mime = "*", use = ["open", "reveal"] },
|
||||
]
|
||||
|
||||
[tasks]
|
||||
micro_workers = 10
|
||||
macro_workers = 25
|
||||
bizarre_retry = 5
|
||||
image_alloc = 536870912 # 512MB
|
||||
image_bound = [0, 0]
|
||||
suppress_preload = false
|
||||
|
||||
[plugin]
|
||||
|
||||
fetchers = [
|
||||
# Mimetype
|
||||
{ id = "mime", name = "*", run = "mime", if = "!mime", prio = "high" },
|
||||
]
|
||||
preloaders = [
|
||||
# example
|
||||
{ mime = "image/{avif,heic,jxl,svg+xml}", run = "magick" },
|
||||
{ mime = "image/*", run = "image" },
|
||||
# Video
|
||||
{ mime = "video/*", run = "video" },
|
||||
# PDF
|
||||
{ mime = "application/pdf", run = "pdf" },
|
||||
# Font
|
||||
{ mime = "font/*", run = "font" },
|
||||
{ mime = "application/vnd.ms-opentype", run = "font" },
|
||||
]
|
||||
previewers = [
|
||||
{ name = "*/", run = "folder", sync = true },
|
||||
# Code
|
||||
{ mime = "text/*", run = "code" },
|
||||
{ mime = "*/{xml,javascript,x-wine-extension-ini}", run = "code" },
|
||||
# JSON
|
||||
{ mime = "application/{json,x-ndjson}", run = "json" },
|
||||
# Image
|
||||
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
|
||||
{ mime = "image/*", run = "image" },
|
||||
# Video
|
||||
{ mime = "video/*", run = "video" },
|
||||
# PDF
|
||||
{ mime = "application/pdf", run = "pdf" },
|
||||
# Archive
|
||||
{ mime = "application/{,g}zip", run = "archive" },
|
||||
{ mime = "application/x-{tar,bzip*,7z-compressed,xz,rar,iso9660-image}", run = "archive" },
|
||||
# Font
|
||||
{ mime = "font/*", run = "font" },
|
||||
{ mime = "application/vnd.ms-opentype", run = "font" },
|
||||
# Fallback
|
||||
{ name = "*", run = "file" },
|
||||
]
|
||||
|
||||
[input]
|
||||
cursor_blink = false
|
||||
|
||||
# cd
|
||||
cd_title = "Change directory:"
|
||||
cd_origin = "top-center"
|
||||
cd_offset = [0, 2, 50, 3]
|
||||
|
||||
# create
|
||||
create_title = ["Create:", "Create (dir):"]
|
||||
create_origin = "hovered"
|
||||
create_offset = [0, 1, 50, 3]
|
||||
|
||||
# rename
|
||||
rename_title = "Rename:"
|
||||
rename_origin = "hovered"
|
||||
rename_offset = [0, 1, 50, 3]
|
||||
|
||||
# trash
|
||||
trash_title = "Move {n} selected file{s} to trash? (y/N)"
|
||||
trash_origin = "hovered"
|
||||
trash_offset = [0, 2, 50, 3]
|
||||
|
||||
# delete
|
||||
delete_title = "Delete {n} selected file{s} permanently? (y/N)"
|
||||
delete_origin = "hovered"
|
||||
delete_offset = [0, 2, 50, 3]
|
||||
|
||||
# filter
|
||||
filter_title = "Filter:"
|
||||
filter_origin = "hovered"
|
||||
filter_offset = [0, 2, 50, 3]
|
||||
|
||||
# find
|
||||
find_title = ["Find next:", "Find previous:"]
|
||||
find_origin = "hovered"
|
||||
find_offset = [0, 2, 50, 3]
|
||||
|
||||
# search
|
||||
search_title = "Search via {n}:"
|
||||
search_origin = "hovered"
|
||||
search_offset = [0, 2, 50, 3]
|
||||
|
||||
# shell
|
||||
shell_title = ["Shell:", "Shell (block):"]
|
||||
shell_origin = "center"
|
||||
shell_offset = [0, 2, 50, 3]
|
||||
|
||||
# overwrite
|
||||
overwrite_title = "Overwrite an existing file? (y/N)"
|
||||
overwrite_origin = "center"
|
||||
overwrite_offset = [0, 2, 50, 3]
|
||||
|
||||
# quit
|
||||
quit_title = "{n} task{s} running, sure to quit? (y/N)"
|
||||
quit_origin = "center"
|
||||
quit_offset = [0, 2, 50, 3]
|
||||
|
||||
[pick]
|
||||
open_title = "Open with:"
|
||||
open_origin = "hovered"
|
||||
open_offset = [0, 1, 50, 7]
|
||||
|
||||
[which]
|
||||
sort_by = "none"
|
||||
sort_sensitive = false
|
||||
sort_reverse = false
|
||||
sort_translit = false
|
||||
Loading…
Add table
Add a link
Reference in a new issue