Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
276 commits
Select commit Hold shift + click to select a range
ccd34fa
refactor: typos
AntoineGS Apr 15, 2025
cf6cb4f
fix: URI conversion for panel would assume file:// prefix
AntoineGS Apr 15, 2025
9822eaf
ci: run vimdocgen on workflow dispatch
MuntasirSZN Apr 15, 2025
b65903d
ci: remove folder creation
AntoineGS Apr 15, 2025
353853c
refactor: eliminate deprecated warnings (#455)
phanen Apr 15, 2025
1b319db
ci: use copilot as project name and disable toc
MuntasirSZN Apr 15, 2025
4e8637c
docs: add vimdoc
MuntasirSZN Apr 15, 2025
49922c9
ci: remove reviewers, fix type in 'commit-message'
AntoineGS Apr 16, 2025
25791dd
ci: allow running job manually
AntoineGS Apr 16, 2025
0b43549
Revert "refactor: eliminate deprecated warnings (#455)"
AntoineGS Apr 16, 2025
935ad69
feat: update to latest Copilot LSP
github-actions[bot] Apr 18, 2025
ec62fd6
feat: leverage virt_text_inline to improve inline suggestions (#465)
AntoineGS Apr 18, 2025
b3988bb
refactor: eliminate deprecated warnings (2nd try) (#464)
phanen Apr 18, 2025
4d4840b
fix: accidentally committed print statements
AntoineGS Apr 19, 2025
dc579f9
fix: broken :Copilot version command
AntoineGS Apr 20, 2025
c0d1824
fix: prevent partial accepts from triggering a new suggestion (#469)
AntoineGS Apr 22, 2025
089ec63
fix: ensure encoding is utf-# (#470)
AntoineGS Apr 22, 2025
fc015b7
fix: resolve stutter when typing over virtual text
AntoineGS Apr 23, 2025
e5b65bb
fix: typo in error message
AntoineGS Apr 24, 2025
2f50ec4
fix: unable to accept panel suggestion (buffer was closed error)
AntoineGS Apr 24, 2025
aef4c9e
test: fix panel test on linux
AntoineGS Apr 25, 2025
a5c390f
feat: update to latest Copilot LSP
github-actions[bot] Apr 25, 2025
ce23086
fix: highlighting of suggestions may become "MatchParen" under certai…
tadashi-aikawa Apr 29, 2025
7ba7386
feat: update to latest Copilot LSP
github-actions[bot] May 6, 2025
2fe34db
doc: update README.md
AntoineGS May 8, 2025
0929c92
feat: update to latest Copilot LSP
github-actions[bot] May 15, 2025
1127cf7
ci: use of correct branch for vimdoc PR generation
AntoineGS May 20, 2025
9ae1021
ci: allow PR creation for vimdocgen
AntoineGS May 20, 2025
642d6e9
docs: update vimdocs
github-actions[bot] May 20, 2025
96e1bb1
fix: issue on Linux and URIs
AntoineGS May 20, 2025
a620a5a
feat: update to latest Copilot LSP
github-actions[bot] May 22, 2025
5f726c8
feat: update to latest Copilot LSP (#493)
github-actions[bot] May 28, 2025
c1bb86a
feat: update to latest Copilot LSP
github-actions[bot] Jun 5, 2025
46f4b7d
feat: update to latest Copilot LSP
github-actions[bot] Jun 27, 2025
b0ffa35
fix: call should_attach on sign_in (#509)
powerman Jul 8, 2025
f26345d
fix: call lsp.start after loading buffer (#508)
powerman Jul 8, 2025
3680beb
feat: update to latest Copilot LSP
github-actions[bot] Jul 8, 2025
f7e2dc7
feat: update to latest Copilot LSP
github-actions[bot] Jul 16, 2025
14bf786
perf: use vim.loop.os_uname() for is_arm (#513)
samirettali Jul 16, 2025
ef6a407
test: update deprecating options
AntoineGS Jul 16, 2025
64422b7
refactor: remove panel horizontal and vertical positions as they have…
proofer Jul 25, 2025
19aacfa
Merge remote-tracking branch 'origin/master'
AntoineGS Jul 25, 2025
4958fb9
feat: update to latest Copilot LSP
github-actions[bot] Jul 25, 2025
d921204
fix: multiple buffers opened cause incorrect should_attach logic (#521)
AntoineGS Jul 28, 2025
8c4b70d
feat: expose is_authenticated() helper and add checkhealth support (#…
cosmicbuffalo Jul 28, 2025
0e1348e
feat: update to latest Copilot LSP
github-actions[bot] Jul 28, 2025
2d7261d
Revert "fix: multiple buffers opened cause incorrect should_attach lo…
AntoineGS Jul 28, 2025
2c3d15c
fix: multiple buffers opened cause incorrect should_attach logic
AntoineGS Jul 29, 2025
045daa5
fix: prevent calling buf_attach_client without a client id
AntoineGS Jul 29, 2025
81cba6d
fix: fail to start when not using lazy loading of plugin
AntoineGS Jul 29, 2025
096c8f6
test: change wait delay
AntoineGS Jul 29, 2025
1c2e65e
fix: ensure buffer is not attached on LSP start as it is long-lived r…
AntoineGS Jul 29, 2025
55e4302
test: add test for filetype exclusion
AntoineGS Jul 29, 2025
f22d869
refactor: improve error handling when node --version does not output …
AntoineGS Jul 31, 2025
60508f9
fix: error message when node --version returns nothing
AntoineGS Aug 1, 2025
b6fe6bb
feat: update to latest Copilot LSP
github-actions[bot] Aug 1, 2025
4c98663
feat: add log file path to :checkhealth
AntoineGS Aug 1, 2025
6ea6bcc
test: add test for lazy loading = false
AntoineGS Aug 1, 2025
6fa90e6
fix: only clear autocmd group if it was created
AntoineGS Aug 1, 2025
5bbc107
fix: ensure logger is set up prior to starting the LSP
AntoineGS Aug 1, 2025
0f2fd38
refactor: log configuration before doing anything that could fail
AntoineGS Aug 1, 2025
9186bbd
feat: update to latest Copilot LSP
github-actions[bot] Aug 14, 2025
9c62af8
chore(deps): bump actions/checkout from 4 to 5
dependabot[bot] Aug 12, 2025
f122741
feat: relax and improve validation for copilot_node_command and nodej…
timhugh Aug 15, 2025
4869bff
feat: add option to suppress limit reched popup (#528)
AbaoFromCUG Aug 15, 2025
5b49bff
docs: update vimdocs
github-actions[bot] Aug 15, 2025
ef3fc4a
feat: update to latest Copilot LSP
github-actions[bot] Aug 16, 2025
75fe839
fix: warn the user if unregistering a keymap fails
AntoineGS Aug 17, 2025
de4e46e
refactor: remove comment add types
AntoineGS Aug 17, 2025
31a5532
test: reduce ambiguity in expected suggestion
AntoineGS Aug 17, 2025
3fd7b50
test: fix failing test
AntoineGS Aug 17, 2025
e4156de
fix: regression where node_command contained spaces (#541)
Aug 20, 2025
b7fe08a
test: disable a failing test
AntoineGS Aug 20, 2025
958f963
Merge remote-tracking branch 'origin/master'
AntoineGS Aug 20, 2025
96f34f8
fix: use buf for FileType autocmd (#539)
Kaiser-Yang Aug 20, 2025
c65160d
test: improve waiting on panel suggestion
AntoineGS Aug 20, 2025
7611deb
feat: update to latest Copilot LSP
github-actions[bot] Aug 20, 2025
635ab1e
Merge remote-tracking branch 'origin/master'
AntoineGS Aug 20, 2025
e405f02
test: fix another test issue
AntoineGS Aug 20, 2025
0753a44
feat: add has_next() function to suggestion
dfrommi Aug 18, 2025
f7bacd9
fix: splitting of copilot_node_command (#545)
Aug 21, 2025
d61c043
feat: update to latest Copilot LSP
github-actions[bot] Aug 22, 2025
633c7aa
feat: update to latest Copilot LSP
github-actions[bot] Aug 22, 2025
f0c0d98
Revert "fix: use buf for FileType autocmd (#539)"
AntoineGS Aug 22, 2025
31c87a0
test: remove temp log file
AntoineGS Aug 26, 2025
e7bfbfb
fix: buffer attachment logic in various conditions
AntoineGS Aug 26, 2025
ac01005
test: refactors
AntoineGS Aug 26, 2025
76c6617
refactor: centralize some logic
AntoineGS Aug 26, 2025
1e37de6
feat: improve `Copilot status` with attach/detached reasons
AntoineGS Aug 26, 2025
7afef52
test: add tests for outstanding issue #551 (unresolved)
AntoineGS Aug 26, 2025
1c11d05
refactor: remove some context logging
AntoineGS Aug 26, 2025
a6af909
fix: make default behavior to attach automatically with most autocmds
AntoineGS Aug 27, 2025
aa00b0b
fix: ensure attachment even when suggestion is disabled
AntoineGS Aug 27, 2025
1b667b4
test: new tests to ensure attach is called
AntoineGS Aug 27, 2025
a2a4747
test: fix test due to attach process change
AntoineGS Aug 27, 2025
04d3760
fix: ensure right buffers are attached/queried with async model
AntoineGS Aug 27, 2025
f55bf8c
fix: prevent manually disabled buffer from automatically re-attaching
AntoineGS Aug 27, 2025
014f2fb
feat: update to latest Copilot LSP
github-actions[bot] Aug 27, 2025
f5a147c
fix: RPC Document for URI not found on ft change
AntoineGS Aug 27, 2025
45d579a
test: increase wait time for CI
AntoineGS Aug 27, 2025
6af0699
ci: remove 0.10.4 from test matrix
AntoineGS Aug 27, 2025
8cfbb5a
feat: add support for `Copilot panel toggle` command
AntoineGS Aug 28, 2025
fc5d6a1
feat: add `Copilot panel close` and `is_open` commands
AntoineGS Aug 28, 2025
2fe9ab1
docs: update vimdocs
github-actions[bot] Aug 28, 2025
e25f975
fix: protect filetype change from an invalid bufnr
AntoineGS Aug 28, 2025
9d4bd5e
feat: update to latest Copilot LSP
github-actions[bot] Aug 28, 2025
164b017
add tests coverage for nodejs module
timhugh Aug 26, 2025
ba4cd43
revert to original get_execute_command
timhugh Aug 26, 2025
d68f6b1
add support for table copilot node command
timhugh Aug 26, 2025
eb5ac7f
rethink system stubs for nodejs tests
timhugh Aug 28, 2025
a267b21
refactor: linting, naming
AntoineGS Aug 28, 2025
46a97dc
test: failing tests on win32 environments
AntoineGS Aug 28, 2025
5a08ab9
fix: lingering ghost text when suggestions have control chars
AntoineGS Aug 29, 2025
c0a8d3e
test: add helper function
AntoineGS Aug 29, 2025
6e43536
refactor: remove instances of ctx logging
AntoineGS Aug 29, 2025
c415c4e
feat: warn about requirement of 0.11+ coming up
AntoineGS Aug 29, 2025
e73fe7c
fix: invalid column placement when control chars present
AntoineGS Aug 29, 2025
407fbd5
feat: update to latest Copilot LSP
github-actions[bot] Sep 3, 2025
d631e31
feat: update to latest Copilot LSP
github-actions[bot] Sep 4, 2025
c2c7cb4
fix: check correct lsp server initialization
AntoineGS Sep 4, 2025
67eebb0
refactor: requires and logging
AntoineGS Sep 4, 2025
c3f2783
test: convert a panel and suggestion tests to use stub lsp
AntoineGS Sep 4, 2025
08894e3
test: test improvements and conversion of test_client to stub LSP
AntoineGS Sep 4, 2025
89adfc7
test: cleanup some tests, finish conversion to LSP mock
AntoineGS Sep 4, 2025
23e1d0b
ci: activate tests on all push/PRs
AntoineGS Sep 4, 2025
5af4c47
ci: add additional checks, rename ci to tests
AntoineGS Sep 4, 2025
81d289a
refactor: warnings cleanup
AntoineGS Sep 4, 2025
8e52d47
feat: update to latest Copilot LSP
github-actions[bot] Sep 10, 2025
8aebaa3
feat: update to latest Copilot LSP
github-actions[bot] Sep 12, 2025
af6410a
feat: update to latest Copilot LSP
github-actions[bot] Sep 16, 2025
f773221
feat: update to latest Copilot LSP
github-actions[bot] Sep 16, 2025
2ac3ab3
feat: next edit suggestion (nes)
AntoineGS Aug 31, 2025
af3114a
docs: update vimdocs
github-actions[bot] Sep 20, 2025
9720f81
chore: remove empty file
AntoineGS Sep 22, 2025
f8fa941
fix: esc key mapping issues
AntoineGS Sep 22, 2025
63be137
refactor: add logging for keymap overrides
AntoineGS Sep 22, 2025
46e9895
fix: support for keymap passthrough to function callbacks
AntoineGS Sep 22, 2025
8b9af0c
fix: ensure keymaps are buffer-aware
AntoineGS Sep 23, 2025
3ea8f8c
fix: missing buffer-based keymap registrations
AntoineGS Sep 23, 2025
cb1a982
fix: ensure bufnr is part of the previous keymap key
AntoineGS Sep 23, 2025
56ae9be
fix: protect against re-registering the same keymap for buffer
AntoineGS Sep 23, 2025
6fba227
fix: ensure key is passed to nvim when there were no previous mappings
AntoineGS Sep 23, 2025
304fc5f
refactor: rework the duplicated keymap logic
AntoineGS Sep 23, 2025
1db764b
refactor: rework logic
AntoineGS Sep 25, 2025
a037c1f
test: add test with default keymap
AntoineGS Sep 25, 2025
a84a0ab
fix: prevent trying to detach from never-attached buffers
AntoineGS Sep 25, 2025
e7dabfd
refactor: use BufEnter instead of FileType autocmd
AntoineGS Sep 25, 2025
abc8bda
refactor: improve readability and annotations
AntoineGS Sep 26, 2025
4725916
feat(suggestions): export clear_preview and update_preview (#571)
samiulsami Sep 26, 2025
1ff8504
refactor!: increase nodejs version requirement for LSP requirement
AntoineGS Sep 26, 2025
fa5ade5
refactor: make stylua happy
AntoineGS Sep 26, 2025
5ca54e6
feat: update to latest Copilot LSP
github-actions[bot] Sep 26, 2025
e5246c3
docs: update vimdocs
github-actions[bot] Sep 26, 2025
619493a
feat: update to latest Copilot LSP
github-actions[bot] Sep 27, 2025
b0cef6c
refactor: add more context to some logs
AntoineGS Sep 28, 2025
724a6fe
fix: allow re-registering keymaps to resolve a reported issue
AntoineGS Sep 28, 2025
36c220b
feat: attempt to restore original keymap when unregistering
AntoineGS Sep 28, 2025
f693e21
fix: prevent infinite retry loop on authentication failure
AntoineGS Sep 29, 2025
f12709a
feat: use of fallback logic on all suggestion keymaps
AntoineGS Sep 30, 2025
3cd5086
refactor!: remove nvim 0.10 support as warned
AntoineGS Sep 30, 2025
a1d94a0
docs: nodejs >= 22 required
marcinjahn Oct 5, 2025
9cc74a0
fix: global `M` in test stub
nihaals Oct 5, 2025
5b0fb32
feat: update to latest Copilot LSP
github-actions[bot] Oct 5, 2025
30b98a4
docs: update vimdocs
github-actions[bot] Oct 5, 2025
3cab232
test: fix failing tests
AntoineGS Oct 9, 2025
cc9b8c3
fix: prev and next keymaps should trigger suggestion
AntoineGS Oct 9, 2025
1404c0f
refactor: unused require and double negation
AntoineGS Oct 9, 2025
4532c77
feat: update to latest Copilot LSP
github-actions[bot] Oct 9, 2025
92e08cd
test: remove unnecessary env file (now that we use mocks)
AntoineGS Oct 9, 2025
3123983
feat: update to latest Copilot LSP
github-actions[bot] Oct 17, 2025
7fe314f
feat: update to latest Copilot LSP
github-actions[bot] Oct 22, 2025
93adf98
feat: update to latest Copilot LSP
github-actions[bot] Oct 25, 2025
2b368ce
Fix git command for nushell compatibility
tsukimizake Oct 25, 2025
3abf634
feat: update to latest Copilot LSP
github-actions[bot] Oct 29, 2025
389cfc5
feat: update to latest Copilot LSP
github-actions[bot] Nov 4, 2025
aac6c72
feat: update to latest Copilot LSP
github-actions[bot] Nov 5, 2025
927053b
feat: update to latest Copilot LSP
github-actions[bot] Nov 5, 2025
a31be88
fix: use nodejs experimental SQLite when nodejs < v25 (#604)
guimochila Nov 7, 2025
5bde2cf
feat: update to latest Copilot LSP
github-actions[bot] Nov 7, 2025
e919876
feat: update to latest Copilot LSP
github-actions[bot] Nov 15, 2025
4383e05
feat: update to latest Copilot LSP
github-actions[bot] Nov 19, 2025
881f99b
feat: update to latest Copilot LSP
github-actions[bot] Dec 2, 2025
efe5638
feat: update to latest Copilot LSP
github-actions[bot] Dec 6, 2025
a064570
feat: update to latest Copilot LSP
github-actions[bot] Dec 10, 2025
508d8b0
feat: update to latest Copilot LSP
github-actions[bot] Dec 12, 2025
e78d1ff
feat: update to latest Copilot LSP
github-actions[bot] Dec 19, 2025
7d9e5f8
chore(deps): bump actions/checkout from 5 to 6
dependabot[bot] Nov 24, 2025
46c5547
chore(deps): bump actions/cache from 4 to 5
dependabot[bot] Dec 15, 2025
279f4fc
chore(deps): bump peter-evans/create-pull-request from 7 to 8
dependabot[bot] Dec 15, 2025
c13f6f5
feat: update to latest Copilot LSP
github-actions[bot] Jan 9, 2026
1eb6f51
feat: add toggle_auto_trigger keymap support (#631)
tjex Jan 10, 2026
5ace9ec
docs: update vimdocs
github-actions[bot] Jan 10, 2026
9688ca7
feat: update to latest Copilot LSP
github-actions[bot] Jan 13, 2026
0ab400d
fix: replace `vim.lsp.stop_client()` with `Client:stop()`
noib3 Jan 12, 2026
d4f6768
feat: update to latest Copilot LSP
github-actions[bot] Jan 17, 2026
fa99d6b
chore: update config defaults in readme (#641)
AntoineGS Jan 18, 2026
2d75114
docs: update vimdocs
github-actions[bot] Jan 18, 2026
2ede080
feat: update to latest Copilot LSP
github-actions[bot] Jan 27, 2026
9b8d77c
feat: update to latest Copilot LSP
github-actions[bot] Jan 28, 2026
48c8886
feat: update to latest Copilot LSP
github-actions[bot] Feb 4, 2026
746cc7a
feat(command): add model command to get/set the model (#643)
doums Feb 4, 2026
5584556
feat: update to latest Copilot LSP
github-actions[bot] Feb 6, 2026
3faffef
feat: update to latest Copilot LSP
github-actions[bot] Feb 6, 2026
dd3e345
feat: update to latest Copilot LSP
github-actions[bot] Feb 14, 2026
2a37f6d
chore: update README
AntoineGS Feb 22, 2026
5c01bad
docs: update vimdocs
github-actions[bot] Feb 22, 2026
f464341
fix: add 30s timeout default to LSP config
AntoineGS Feb 23, 2026
3fba29d
fix: cutting off of suggestion when before cursor
AntoineGS Feb 24, 2026
27177dd
ci: add make lint and pre-commit hook
AntoineGS Feb 24, 2026
5620107
chore: fix makefile, add make deps
AntoineGS Feb 22, 2026
ce7bfeb
chore: add CLAUDE.md
AntoineGS Feb 22, 2026
9193974
fix: silence repeated 'copilot is disabled' warnings
AntoineGS Feb 22, 2026
a6a4935
perf: skip suggestion requests when copilot client is disabled
AntoineGS Feb 22, 2026
69f7a96
feat: show disabled state in checkhealth output
AntoineGS Feb 22, 2026
5406260
tests: claude-generated test for better coverage
AntoineGS Feb 22, 2026
ee32a28
fix: curl detection
AntoineGS Feb 22, 2026
69a0dc5
fix: invalid comparison
AntoineGS Feb 22, 2026
2186c76
fix: is_visible() returning stale state after accept
AntoineGS Feb 22, 2026
e43c9e5
fix: prevent infinite detach/re-attach loop on non-buflisted buffers
AntoineGS Feb 22, 2026
397ac41
fix: prevent infinite detach/re-attach loop on non-buflisted buffers
AntoineGS Feb 22, 2026
8fe616b
tests: fix tests on Windows
AntoineGS Feb 22, 2026
ef4bfc5
tests: fix failing test due to leftover file
AntoineGS Feb 24, 2026
9f91e57
feat: update to latest Copilot LSP
github-actions[bot] Feb 26, 2026
1eecd6c
tests: remove version testing as it will always fail
AntoineGS Feb 26, 2026
4c50628
fix: file rename yields URI error
AntoineGS Feb 28, 2026
00446a6
feat: update to latest Copilot LSP
github-actions[bot] Feb 28, 2026
3061c49
feat: update to latest Copilot LSP
github-actions[bot] Mar 3, 2026
89c8ada
fix: race in should_attach
powerman Mar 4, 2026
0fb3cb3
feat: update to latest Copilot LSP
github-actions[bot] Mar 4, 2026
10c1c88
docs: update vimdocs
github-actions[bot] Mar 4, 2026
f9b93fe
ci: add release-please workflow for automated SemVer releases
AntoineGS Mar 5, 2026
8e4f209
ci: move version back to start at v2
AntoineGS Mar 6, 2026
1b57ea6
chore: update to latest Copilot LSP
github-actions[bot] Mar 6, 2026
437b18f
chore(master): release 2.0.0
github-actions[bot] Mar 6, 2026
575646d
chore: update to latest Copilot LSP
github-actions[bot] Mar 7, 2026
cf2c59c
chore: update to latest Copilot LSP
github-actions[bot] Mar 13, 2026
11f6d96
chore: update to latest Copilot LSP
github-actions[bot] Mar 13, 2026
8e2a918
fix: safeguards against orphaned copilot servers
AntoineGS Mar 13, 2026
e4bd38b
chore: update to latest Copilot LSP
github-actions[bot] Mar 18, 2026
0552b44
chore: update to latest Copilot LSP
github-actions[bot] Mar 18, 2026
9204088
fix: Tab passthrough
AntoineGS Mar 24, 2026
192b48d
chore: update to latest Copilot LSP
github-actions[bot] Mar 24, 2026
538f15c
chore(master): release 2.0.1
github-actions[bot] Mar 24, 2026
0a3e091
chore: update to latest Copilot LSP
github-actions[bot] Mar 28, 2026
faa347c
chore: update to latest Copilot LSP
github-actions[bot] Mar 31, 2026
07aa571
chore: update to latest Copilot LSP
github-actions[bot] Apr 3, 2026
736b88c
fix(keymaps): preserve special insert keys in passthrough fallback
noib3 Apr 9, 2026
f79864f
chore: update to latest Copilot LSP
github-actions[bot] Apr 11, 2026
555fe9d
fix: wrap maparg in nvim_buf_call to prevent capturing keymaps from t…
mwojick Apr 11, 2026
ad7e729
chore(master): release 2.0.2
github-actions[bot] Apr 11, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/copilot/dist/** -whitespace -diff
/dist/** -whitespace -diff
*.lua eol=lf
5 changes: 5 additions & 0 deletions .githooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -e

echo "Running lint checks..."
make lint
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: github-actions
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 10
26 changes: 26 additions & 0 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Format

on: [push, pull_request]

jobs:
format:
name: Stylua
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- run: date +%W > weekly

- name: Restore cache
id: cache
uses: actions/cache@v5
with:
path: |
~/.cargo/bin
key: ${{ runner.os }}-cargo-${{ hashFiles('weekly') }}

- name: Install
if: steps.cache.outputs.cache-hit != 'true'
run: cargo install stylua

- name: Format
run: stylua --check lua/ --config-path=.stylua.toml
18 changes: 18 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Lint

on: [push, pull_request]

jobs:
lint:
name: Luacheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Setup
run: |
sudo apt-get update
sudo apt-get install luarocks -y
sudo luarocks install luacheck

- name: Lint
run: luacheck lua/ --globals vim
21 changes: 21 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Automated releases based on conventional commits
# https://github.com/googleapis/release-please-action

name: Release

on:
push:
branches:
- master
workflow_dispatch:

permissions:
contents: write
pull-requests: write

jobs:
release:
name: release
runs-on: ubuntu-latest
steps:
- uses: googleapis/release-please-action@v4
40 changes: 40 additions & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Tests

on: [push, pull_request]

jobs:
unit_tests:
name: unit tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-24.04, ubuntu-24.04-arm, macos-latest, windows-2025]
rev: [nightly, stable]
include:
- os: ubuntu-24.04
install-rg: sudo apt-get update && sudo apt-get install -y nodejs curl
- os: ubuntu-24.04-arm
install-rg: sudo apt-get update && sudo apt-get install -y nodejs curl
- os: macos-latest
install-rg: brew update && brew install node curl
- os: windows-2025
install-rg: choco install nodejs-lts curl

steps:
- uses: actions/checkout@v6

- uses: rhysd/action-setup-vim@v1
with:
neovim: true
version: ${{ matrix.rev }}

- name: Prepare
run: |
${{ matrix.install-rg }}
git clone --filter=blob:none https://github.com/nvim-mini/mini.nvim deps/mini.nvim

- name: Run tests
run: |
nvim --version
make test
15 changes: 15 additions & 0 deletions .github/workflows/typecheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Typecheck

on: [push, pull_request]

jobs:
build:
name: Type Check Code Base
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v6
- uses: stevearc/nvim-typecheck-action@v2
with:
level: Warning
configpath: ".luarc.json"
17 changes: 12 additions & 5 deletions .github/workflows/update-copilot-nodejs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,16 @@ on:
- cron: "0 0 * * *"
push:
branches: [master]
workflow_dispatch:

jobs:
update_copilot_lsp:
runs-on: ubuntu-latest
name: Update Copilot LSP
if: github.repository == 'zbirenbaum/copilot.lua'
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v6

- name: Create directory
run: |
Expand All @@ -22,18 +24,23 @@ jobs:
run: |
curl -s https://api.github.com/repos/github/copilot-language-server-release/releases/latest | grep "browser_download_url.*copilot-language-server-js-.*zip" | cut -d : -f 2,3 | tr -d \" | wget -vi -

- name: Update version in util.lua
run: |
COPILOT_LATEST_RELEASE_VER=$(curl -s https://api.github.com/repos/github/copilot-language-server-release/releases | jq -r '.[0].tag_name') && sed -i.bak -E "s/(version = \")[^\"]+(\",)/\1$COPILOT_LATEST_RELEASE_VER\2/" "lua/copilot/util.lua" && rm lua/copilot/util.lua.bak

- name: Unzip LSP
run: |
unzip -o copilot-language-server-js-*.zip -d copilot/js
rm copilot-language-server-js-*.zip

- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
uses: peter-evans/create-pull-request@v8
with:
add-paths: "copilot/js/*"
add-paths: |
copilot/js/*
lua/copilot/util.lua
author: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
base: master
branch: create-pull-request/update-copilot-lsp
commit-message: "feat: update to latest Copilot LSP"
reviewers: MunifTanjim,zbirenbaum,AntoineGS
commit-message: "chore: update to latest Copilot LSP"
title: "Update Copilot LSP"
36 changes: 36 additions & 0 deletions .github/workflows/vimdocgen.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Auto Generate Vimdoc
on:
push:
branches: [master]
paths:
- README.md
- .github/workflows/vimdocgen.yml
workflow_dispatch:

permissions:
contents: write
pull-requests: write

jobs:
docs:
runs-on: ubuntu-latest
name: Convert Markdown to Vimdoc
steps:
- uses: actions/checkout@v6
- uses: kdheepak/panvimdoc@main
with:
vimdoc: "copilot"
version: "NVIM v0.11.0"
description: "Fully featured & enhanced replacement for copilot.vim complete with API for interacting with Github Copilot"
titledatepattern: "%d %B, %Y"
toc: false
- name: Create Pull Request
uses: peter-evans/create-pull-request@v8
with:
add-paths: |
doc/*
author: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
base: master
branch: create-pull-request/autogenerate-vimdoc
commit-message: "docs: update vimdocs"
title: "Update Vimdocs"
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
tests/logs
tests/env.lua
tests/deps
deps/

tests/files/test.txt
4 changes: 4 additions & 0 deletions .luacheckrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---@diagnostic disable-next-line: lowercase-global
globals = { "vim", "describe", "it", "before_each", "after_each", "assert", "async", "MiniTest" }
---@diagnostic disable-next-line: lowercase-global
max_comment_line_length = 420
21 changes: 16 additions & 5 deletions .luarc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
{
"runtime.version": "Lua 5.1",
"workspace.library": ["deps"],
"workspace.ignoreDir": ["deps"]
}
{
"runtime": {
"version": "LuaJIT",
"pathStrict": true
},
"type": {
"checkTableShape": true
},
"diagnostics.globals": [
"describe",
"it",
"before_each",
"MiniTest",
"after_each"
]
}
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "2.0.2"
}
Loading