File tree Expand file tree Collapse file tree 1 file changed +24
-46
lines changed
plugins/by-name/blink-copilot Expand file tree Collapse file tree 1 file changed +24
-46
lines changed Original file line number Diff line number Diff line change 1
1
{ lib , ... } :
2
- lib . nixvim . plugins . mkNeovimPlugin {
2
+ let
3
3
name = "blink-copilot" ;
4
- package = "blink-copilot" ;
4
+ in
5
+ lib . nixvim . plugins . mkNeovimPlugin {
6
+ inherit name ;
5
7
6
8
maintainers = [ lib . maintainers . khaneliman ] ;
7
9
8
- description = ''
9
- This plugin should be configured through blink-cmp's `sources.providers` settings.
10
-
11
- For example:
12
-
13
- ```nix
14
- plugins.blink-cmp = {
15
- enable = true;
16
- settings.sources.providers = {
17
- copilot = {
18
- async = true;
19
- module = "blink-copilot";
20
- name = "copilot";
21
- score_offset = 100;
22
- # Optional configurations
23
- opts = {
24
- max_completions = 3;
25
- max_attempts = 4;
26
- kind = "Copilot";
27
- debounce = 750;
28
- auto_refresh = {
29
- backward = true;
30
- forward = true;
31
- };
32
- };
33
- };
10
+ imports = [
11
+ ( lib . nixvim . modules . mkBlinkPluginModule {
12
+ pluginName = name ;
13
+ # TODO: compute a sane-default
14
+ sourceName = "copilot" ;
15
+ settingsExample = {
16
+ async = true ;
17
+ score_offset = 100 ;
34
18
} ;
19
+ } )
20
+ ] ;
21
+
22
+ settingsExample = {
23
+ max_completions = 3 ;
24
+ max_attempts = 4 ;
25
+ kind = "Copilot" ;
26
+ debounce = 750 ;
27
+ auto_refresh = {
28
+ backward = true ;
29
+ forward = true ;
35
30
} ;
36
- ```
37
-
38
- And then you can add it to blink-cmp's `sources.default` option:
39
-
40
- ```nix
41
- plugins.blink-cmp = {
42
- enable = true;
43
- settings.sources.default = [
44
- "lsp"
45
- "path"
46
- "luasnip"
47
- "buffer"
48
- "copilot"
49
- ];
50
- };
51
- ```
52
- '' ;
31
+ } ;
53
32
54
33
# Configured through blink-cmp
55
34
callSetup = false ;
56
35
hasLuaConfig = false ;
57
- hasSettings = false ;
58
36
59
37
extraConfig = {
60
38
plugins . copilot-lua . enable = lib . mkDefault true ;
You can’t perform that action at this time.
0 commit comments