blob: 082419e829764ebef964b59821e20e3a7298b372 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
# Wofi
# https://hg.sr.ht/~scoopta/wofi
# Dependencies:
# – fd (https://github.com/sharkdp/fd)
# – ripgrep (https://github.com/BurntSushi/ripgrep)
provide-module connect-wofi %{
# Modules
require-module connect
# Register our paths
set-option -add global connect_paths "%opt{connect_modules_path}/wofi/aliases" "%opt{connect_modules_path}/wofi/commands"
# Commands
# Files
define-command wofi-files -params .. -file-completion -docstring 'Open files with Wofi' %{
$ :wofi-files %arg{@}
}
# Buffers
define-command wofi-buffers -params ..1 -buffer-completion -docstring 'Open buffers with Wofi' %{
$ :wofi-buffers %arg{@}
}
# Grep
define-command wofi-grep -params .. -file-completion -docstring 'Open files (search by content) with Wofi' %{
$ :wofi-grep %arg{@}
}
# Aliases
alias global wofi wofi-files
}
|