diff --git a/.config/yazi/flavors/kanagawa.yazi/LICENSE b/.config/yazi/flavors/kanagawa.yazi/LICENSE new file mode 100644 index 0000000..1b1dfdc --- /dev/null +++ b/.config/yazi/flavors/kanagawa.yazi/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Dmitry Nefedov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/.config/yazi/flavors/kanagawa.yazi/LICENSE-tmtheme b/.config/yazi/flavors/kanagawa.yazi/LICENSE-tmtheme new file mode 100644 index 0000000..1b1dfdc --- /dev/null +++ b/.config/yazi/flavors/kanagawa.yazi/LICENSE-tmtheme @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Dmitry Nefedov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/.config/yazi/flavors/kanagawa.yazi/README.md b/.config/yazi/flavors/kanagawa.yazi/README.md new file mode 100644 index 0000000..72cca6a --- /dev/null +++ b/.config/yazi/flavors/kanagawa.yazi/README.md @@ -0,0 +1,36 @@ +
+ Yazi logo +
+ +

+ Kanagawa Flavor for Yazi +

+ +## 👀 Preview + + + +## 🎨 Installation + +```bash +ya pack -a dangooddd/kanagawa +``` + +## ⚙️ Usage + +> [!Note] +> To achieve the look like in the screenshot you also need to install +> [full-border](https://github.com/yazi-rs/plugins/tree/main/full-border.yazi) plugin! + +Add these lines to your `theme.toml` configuration file to use it: + +```toml +[flavor] +dark = "kanagawa" +``` + +## 📜 License + +The flavor is MIT-licensed, and the included tmTheme is also MIT-licensed. + +Check the [LICENSE](LICENSE) and [LICENSE-tmtheme](LICENSE-tmtheme) file for more details. diff --git a/.config/yazi/flavors/kanagawa.yazi/flavor.toml b/.config/yazi/flavors/kanagawa.yazi/flavor.toml new file mode 100644 index 0000000..d46ff50 --- /dev/null +++ b/.config/yazi/flavors/kanagawa.yazi/flavor.toml @@ -0,0 +1,137 @@ +## Color palette +## Check https://github.com/rebelot/kanagawa.nvim for more details +# sumiInk0 "#16161d" dark bg +# sumiInk3 "#1f1f28" bg +# sumiInk4 "#2a2a37" +# sumiInk6 "#54546d" +# fujiWhite "#dcd7ba" fg +# oldWhite "#c8c093" dark fg +# fujiGray "#727169" +# peachRed "#ff5d62" +# autumnRed "#c34043" +# crystalBlue "#7e9cd8" +# waveRed "#e46876" +# carpYellow "#e6c384" +# springGreen "#98bb6c" +# autumnGreen "#76946a" +# oniViolet "#957fb8" +# waveAqua1 "#6a9589" +# surimiOrange "#ffa066" +# waveAqua2 "#7aa89f" + +[manager] +marker_copied = { fg = "#98bb6c", bg = "#98bb6c" } +marker_cut = { fg = "#e46876", bg = "#e46876" } +marker_marked = { fg = "#957fb8", bg = "#957fb8" } +marker_selected = { fg = "#ffa066", bg = "#ffa066" } + +cwd = { fg = "#e6c384" } +hovered = { reversed = true } +preview_hovered = { reversed = true } + +find_keyword = { fg = "#ffa066", bg = "#1f1f28" } +find_position = {} + +tab_active = { reversed = true } +tab_inactive = {} +tab_width = 1 + +count_copied = { fg = "#1f1f28", bg = "#98bb6c" } +count_cut = { fg = "#1f1f28", bg = "#e46876" } +count_selected = { fg = "#1f1f28", bg = "#e6c384" } + +border_symbol = "│" +border_style = { fg = "#dcd7ba" } + + +[mode] +normal_main = { fg = "#1f1f28", bg = "#7e9cd8" } +normal_alt = { fg = "#7e9cd8", bg = "#2a2a37" } +select_main = { fg = "#1f1f28", bg = "#957fb8" } +select_alt = { fg = "#957fb8", bg = "#2a2a37" } +unset_main = { fg = "#1f1f28", bg = "#e6c384" } +unset_alt = { fg = "#e6c384", bg = "#2a2a37" } + + +[status] +sep_left = { open = "", close = "" } +sep_right = { open = "", close = "" } +overall = { fg = "#c8c093", bg = "#16161d" } + +progress_label = { fg = "#7e9cd8", bg = "#2a2a37", bold = true } +progress_normal = { fg = "#2a2a37", bg = "#1f1f28" } +progress_error = { fg = "#2a2a37", bg = "#1f1f28" } + +perm_type = { fg = "#98bb6c" } +perm_read = { fg = "#e6c384" } +perm_write = { fg = "#ff5d62" } +perm_exec = { fg = "#7aa89f" } +perm_sep = { fg = "#957fb8" } + + +[pick] +border = { fg = "#7fb4ca" } +active = { fg = "#957fb8", bold = true } +inactive = {} + +[input] +border = { fg = "#7fb4ca" } +title = {} +value = {} +selected = { reversed = true } + +[completion] +border = { fg = "#7fb4ca" } +active = { reversed = true } +inactive = {} + +[tasks] +border = { fg = "#7fb4ca" } +title = {} +hovered = { fg = "#957fb8" } + +[which] +cols = 2 +separator = " - " +separator_style = { fg = "#727169" } +mask = { bg = "#16161d" } +rest = { fg = "#727169" } +cand = { fg = "#7e9cd8" } +desc = { fg = "#54546d" } + +[help] +on = { fg = "#7aa89f" } +run = { fg = "#957fb8" } +desc = {} +hovered = { reversed = true, bold = true } +footer = { fg = "#1f1f28", bg = "#dcd7ba" } + +[notify] +title_info = { fg = "#98bb6c" } +title_warn = { fg = "#e6c384" } +title_error = { fg = "#ff5d62" } + +[filetype] +rules = [ + # images + { mime = "image/*", fg = "#e6c384" }, + + # media + { mime = "{audio,video}/*", fg = "#957fb8" }, + + # archives + { mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", fg = "#e46876" }, + + # documents + { mime = "application/{pdf,doc,rtf,vnd.*}", fg = "#6a9589" }, + + # broken links + { name = "*", is = "orphan", fg = "#c34043" }, + + # executables + { name = "*", is = "exec", fg = "#76946a" }, + + # fallback + { name = "*", fg = "#dcd7ba" }, + { name = "*/", fg = "#7e9cd8" }, +] diff --git a/.config/yazi/flavors/kanagawa.yazi/preview.png b/.config/yazi/flavors/kanagawa.yazi/preview.png new file mode 100644 index 0000000..87d0767 Binary files /dev/null and b/.config/yazi/flavors/kanagawa.yazi/preview.png differ diff --git a/.config/yazi/flavors/kanagawa.yazi/tmtheme.xml b/.config/yazi/flavors/kanagawa.yazi/tmtheme.xml new file mode 100644 index 0000000..737e459 --- /dev/null +++ b/.config/yazi/flavors/kanagawa.yazi/tmtheme.xml @@ -0,0 +1,448 @@ + + + + + name + Kanagawa + settings + + + settings + + background + #1F1F28 + caret + #C8C093 + foreground + #DCD7BA + invisibles + #54546D + lineHighlight + #2D4F67 + selection + #2D4F67 + findHighlight + #2D4F67 + selectionBorder + #222218 + gutterForeground + #54546D + + + + name + Comment + scope + comment + settings + + foreground + #727169 + + + + name + String + scope + string + settings + + foreground + #98BB6C + + + + name + Number + scope + constant.numeric + settings + + foreground + #D27E99 + + + + name + Built-in constant + scope + constant.language + settings + + foreground + #FFA066 + + + + name + User-defined constant + scope + constant.character, constant.other + settings + + foreground + #E6C384 + + + + name + Variable + scope + variable + settings + + fontStyle + #E6C384 + + + + name + Ruby's @variable + scope + variable.other.readwrite.instance + settings + + fontStyle + + foreground + #E6C384 + + + + name + String interpolation + scope + constant.character.escaped, constant.character.escape, string source, string source.ruby + settings + + fontStyle + + foreground + #C0A36E + + + + name + Keyword + scope + keyword + settings + + foreground + #E46876 + + + + name + Storage + scope + storage + settings + + fontStyle + + foreground + #957FB8 + + + + name + Storage type + scope + storage.type + settings + + foreground + #957FB8 + + + + name + Class name + scope + entity.name.class + settings + + foreground + #7AA89F + + + + name + Inherited class + scope + entity.other.inherited-class + settings + + foreground + #7AA89F + + + + name + Function name + scope + entity.name.function + settings + + fontStyle + + foreground + #7E9CD8 + + + + name + Function argument + scope + variable.parameter + settings + + foreground + #b8b4d0 + + + + name + Tag name + scope + entity.name.tag + settings + + fontStyle + + foreground + #7FB4CA + + + + name + Tag attribute + scope + entity.other.attribute-name + settings + + fontStyle + + foreground + #E6C384 + + + + name + Library function + scope + support.function + settings + + fontStyle + + foreground + #7FB4CA + + + + name + Library constant + scope + support.constant + settings + + fontStyle + + foreground + #7FB4CA + + + + name + Library class/type + scope + support.type, support.class + settings + + foreground + #7AA89F + + + + name + Library variable + scope + support.other.variable + settings + + foreground + #FFA066 + + + + name + Invalid + scope + invalid + settings + + fontStyle + + foreground + #FF5D62 + + + + name + Invalid deprecated + scope + invalid.deprecated + settings + + foreground + #717C7C + + + + name + JSON String + scope + meta.structure.dictionary.json string.quoted.double.json + settings + + foreground + #957FB8 + + + + name + diff.header + scope + meta.diff, meta.diff.header + settings + + foreground + #7E9CD8 + + + + name + diff.deleted + scope + markup.deleted + settings + + background + #43242B + + + + name + diff.inserted + scope + markup.inserted + settings + + background + #2B3328 + + + + name + diff.changed + scope + markup.changed + settings + + background + #49443C + + + + scope + constant.numeric.line-number.find-in-files - match + settings + + foreground + #54546D + + + + scope + entity.name.filename + settings + + foreground + #C8C093 + + + + scope + message.error + settings + + foreground + #E82424 + + + + name + JSON Punctuation + scope + punctuation.definition.string.begin.json - meta.structure.dictionary.value.json, punctuation.definition.string.end.json - meta.structure.dictionary.value.json + settings + + foreground + #9CABCA + + + + name + JSON Structure + scope + meta.structure.dictionary.json string.quoted.double.json + settings + + foreground + #957FB8 + + + + name + JSON String + scope + meta.structure.dictionary.value.json string.quoted.double.json + settings + + foreground + #ffffff + + + + name + Escape Characters + scope + constant.character.escape + settings + + foreground + #FF5D62 + + + + name + Regular Expressions + scope + string.regexp + settings + + foreground + #E6C384 + + + + uuid + 592FC036-6BB7-4676-A2F5-2894D48C8E33 + colorSpaceName + sRGB + semanticClass + theme.dark.kanagawa + + diff --git a/.config/yazi/keymap.toml b/.config/yazi/keymap.toml new file mode 100644 index 0000000..282dac6 --- /dev/null +++ b/.config/yazi/keymap.toml @@ -0,0 +1,4 @@ +[[manager.prepend_keymap]] +on = [ "g", "i" ] +run = "plugin lazygit" +desc = "run lazygit" diff --git a/.config/yazi/package.toml b/.config/yazi/package.toml new file mode 100644 index 0000000..b167610 --- /dev/null +++ b/.config/yazi/package.toml @@ -0,0 +1,9 @@ +[[plugin.deps]] +use = "Lil-Dank/lazygit" +rev = "7a08a09" +hash = "a1fa2b3e1826c3a34804ea8c548e9f80" + +[[flavor.deps]] +use = "dangooddd/kanagawa" +rev = "31167ed" +hash = "a04e157148549bacbb2831aab0e6e8cb" diff --git a/.config/yazi/plugins/lazygit.yazi/LICENSE b/.config/yazi/plugins/lazygit.yazi/LICENSE new file mode 100644 index 0000000..ae1f60d --- /dev/null +++ b/.config/yazi/plugins/lazygit.yazi/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Darius + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/.config/yazi/plugins/lazygit.yazi/README.md b/.config/yazi/plugins/lazygit.yazi/README.md new file mode 100644 index 0000000..e96c9c6 --- /dev/null +++ b/.config/yazi/plugins/lazygit.yazi/README.md @@ -0,0 +1,29 @@ +# lazygit.yazi +Plugin for [Yazi](https://github.com/sxyazi/yazi) to manage git repos with [lazygit](https://github.com/jesseduffield/lazygit) +## Dependencies +Make sure [lazygit](https://github.com/jesseduffield/lazygit) is installed and in your `PATH`. +## Installation + +### Using `ya pack` +``` +ya pack -a Lil-Dank/lazygit +``` + +### Manual +**Linux/macOS** +``` +git clone https://github.com/Lil-Dank/lazygit.yazi.git ~/.config/yazi/plugins/lazygit.yazi +``` +**Windows** +``` +git clone https://github.com/Lil-Dank/lazygit.yazi.git %AppData%\yazi\config\plugins\lazygit.yazi +``` +## Configuration +add this to your **keymap.toml** file +```toml +[[manager.prepend_keymap]] +on = [ "g", "i" ] +run = "plugin lazygit" +desc = "run lazygit" +``` +you can customize the keybinding however you like. Please refer to the [keymap.toml](https://yazi-rs.github.io/docs/configuration/keymap) documentation diff --git a/.config/yazi/plugins/lazygit.yazi/main.lua b/.config/yazi/plugins/lazygit.yazi/main.lua new file mode 100644 index 0000000..32d7f18 --- /dev/null +++ b/.config/yazi/plugins/lazygit.yazi/main.lua @@ -0,0 +1,31 @@ +return { + entry = function() + local output = Command("git"):arg("status"):stderr(Command.PIPED):output() + if output.stderr ~= "" then + ya.notify({ + title = "lazygit", + content = "Not in a git directory\nError: " .. output.stderr, + level = "warn", + timeout = 5, + }) + else + permit = ya.hide() + local output, err_code = Command("lazygit"):stderr(Command.PIPED):output() + if err_code ~= nil then + ya.notify({ + title = "Failed to run lazygit command", + content = "Status: " .. err_code, + level = "error", + timeout = 5, + }) + elseif not output.status.success then + ya.notify({ + title = "lazygit in" .. cwd .. "failed, exit code " .. output.status.code, + content = output.stderr, + level = "error", + timeout = 5, + }) + end + end + end, +} diff --git a/.config/yazi/theme.toml b/.config/yazi/theme.toml new file mode 100644 index 0000000..26a4db0 --- /dev/null +++ b/.config/yazi/theme.toml @@ -0,0 +1,2 @@ +[flavor] +dark = "kanagawa" diff --git a/.config/yazi/yazi.toml b/.config/yazi/yazi.toml new file mode 100644 index 0000000..e69de29 diff --git a/README.md b/README.md new file mode 100644 index 0000000..e69de29