File tree 5 files changed +112
-0
lines changed
plugins/by-name/telescope/extensions
tests/test-sources/plugins/by-name/telescope
5 files changed +112
-0
lines changed Original file line number Diff line number Diff line change @@ -87,6 +87,7 @@ class State(Enum):
87
87
"project" : False ,
88
88
"ui-select" : False ,
89
89
"undo" : True ,
90
+ "zoxide" : False ,
90
91
}.items ():
91
92
KNOWN_PATHS [
92
93
f"plugins/by-name/telescope/extensions/{ telescope_extension_name } .nix"
Original file line number Diff line number Diff line change 10
10
./project.nix
11
11
./ui-select.nix
12
12
./undo.nix
13
+ ./zoxide.nix
13
14
] ;
14
15
}
Original file line number Diff line number Diff line change
1
+ let
2
+ mkExtension = import ./_mk-extension.nix ;
3
+ in
4
+ mkExtension {
5
+ name = "zoxide" ;
6
+ package = "telescope-zoxide" ;
7
+
8
+ settingsExample = {
9
+ prompt_title = "Zoxide Folder List" ;
10
+ mappings = {
11
+ "<C-b>" = {
12
+ keepinsert = true ;
13
+ action . __raw = ''
14
+ function(selection)
15
+ file_browser.file_browser({ cwd = selection.path })
16
+ end
17
+ '' ;
18
+ } ;
19
+ } ;
20
+ } ;
21
+ }
Original file line number Diff line number Diff line change
1
+ {
2
+ empty = {
3
+ plugins = {
4
+ telescope = {
5
+ enable = true ;
6
+ extensions . zoxide . enable = true ;
7
+ } ;
8
+ web-devicons . enable = true ;
9
+ } ;
10
+ } ;
11
+
12
+ defaults = {
13
+ plugins = {
14
+ web-devicons . enable = true ;
15
+ telescope = {
16
+ enable = true ;
17
+
18
+ extensions . zoxide = {
19
+ enable = true ;
20
+
21
+ settings = {
22
+ prompt_title = "[ Zoxide List ]" ;
23
+ list_command = "zoxide query -ls" ;
24
+ mappings = {
25
+ default = {
26
+ action . __raw = ''
27
+ function(selection)
28
+ vim.cmd.cd(selection.path)
29
+ end
30
+ '' ;
31
+ after_action . __raw = ''
32
+ function(selection)
33
+ vim.notify("Directory changed to " .. selection.path)
34
+ end
35
+ '' ;
36
+ } ;
37
+ "<C-s>" . action . __raw =
38
+ "require('telescope._extensions.zoxide.utils').create_basic_command('split')" ;
39
+ "<C-v>" . action . __raw =
40
+ "require('telescope._extensions.zoxide.utils').create_basic_command('vsplit')" ;
41
+ "<C-e>" . action . __raw = "require('telescope._extensions.zoxide.utils').create_basic_command('edit')" ;
42
+ "<C-f>" = {
43
+ keepinsert = true ;
44
+ action . __raw = ''
45
+ function(selection)
46
+ builtin.find_files({ cwd = selection.path })
47
+ end
48
+ '' ;
49
+ } ;
50
+ "<C-t>" . action . __raw = ''
51
+ function(selection)
52
+ vim.cmd.tcd(selection.path)
53
+ end
54
+ '' ;
55
+ } ;
56
+ } ;
57
+ } ;
58
+ } ;
59
+ } ;
60
+ } ;
61
+
62
+ example = {
63
+ plugins = {
64
+ web-devicons . enable = true ;
65
+ telescope = {
66
+ enable = true ;
67
+
68
+ extensions . zoxide = {
69
+ enable = true ;
70
+
71
+ settings = {
72
+ prompt_title = "Zoxide Folder List" ;
73
+ mappings = {
74
+ "<C-b>" = {
75
+ keepinsert = true ;
76
+ action . __raw = ''
77
+ function(selection)
78
+ file_browser.file_browser({ cwd = selection.path })
79
+ end
80
+ '' ;
81
+ } ;
82
+ } ;
83
+ } ;
84
+ } ;
85
+ } ;
86
+ } ;
87
+ } ;
88
+ }
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ tro = "tro" # ./plugins/utils/spectre.nix
16
16
protols = " protols" # ./plugins/lsp/lsp-packages.nix
17
17
compatibilty = " compatibilty" # ./plugins/by-name/visual-multi/default.nix
18
18
Maco = " Maco" # ./plugins/by-name/femaco
19
+ Typ = " Typ" # ./flake/dev/list-plugins/list-plugins.py
19
20
20
21
[type .patch ]
21
22
extend-glob = [" *.patch" ]
You can’t perform that action at this time.
0 commit comments