diff options
| author | Fasamii <fasami0512@gmail.com> | 2026-02-07 15:41:38 +0100 |
|---|---|---|
| committer | Fasamii <fasami0512@gmail.com> | 2026-02-07 15:41:38 +0100 |
| commit | 7a65a3a313d17e25d372689c027b558c9cc07d54 (patch) | |
| tree | 09832af4d06dd38da6bc3f3d8c307a8ab9d0fc58 /lua/netrw-icons/parse.lua | |
| parent | 7f8edb90ad9dd8523de40435685cfc0c110c220f (diff) | |
| download | netrw-icons.nvim-7a65a3a313d17e25d372689c027b558c9cc07d54.tar.gz netrw-icons.nvim-7a65a3a313d17e25d372689c027b558c9cc07d54.tar.bz2 netrw-icons.nvim-7a65a3a313d17e25d372689c027b558c9cc07d54.tar.xz netrw-icons.nvim-7a65a3a313d17e25d372689c027b558c9cc07d54.tar.zst | |
Extended configuration options
Diffstat (limited to 'lua/netrw-icons/parse.lua')
| -rw-r--r-- | lua/netrw-icons/parse.lua | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/lua/netrw-icons/parse.lua b/lua/netrw-icons/parse.lua index 911a1c6..5245645 100644 --- a/lua/netrw-icons/parse.lua +++ b/lua/netrw-icons/parse.lua @@ -10,7 +10,8 @@ local M = {} M.TYPE_DIR = 0 M.TYPE_FILE = 1 -M.TYPE_SYMLINK = 2 +M.TYPE_EXE = 2 +M.TYPE_SYMLINK = 3 ---@alias rwNode{name:string, icon:number, type:number} @@ -125,6 +126,10 @@ local parse_liststyle_3 = function(line) local name = content; + if name:sub(-1) == "*" then + type = M.TYPE_EXE; + end + local _, _, link, link_target = string.find(content, "^(.+)@\t%s*%-%->%s*(.+)") if link then type = M.TYPE_SYMLINK; @@ -138,9 +143,7 @@ local parse_liststyle_3 = function(line) return { name = name, - -- path = current_dir .. "/" .. name, icon = tree_end, - -- lsp = tree_end + #content, type = type, } end |
