Commit graph

3408 commits

Author SHA1 Message Date
Matt Sturgeon
1ff5e1a33b
docs/server: open browser using xdg-open 2025-05-22 13:48:58 +01:00
Matt Sturgeon
601d4309ed
docs/server: print the URL once serving 2025-05-22 13:48:58 +01:00
Matt Sturgeon
f3342bdbd4
docs: refactor serve-docs; add nix run .#docs
Refactor `serve-docs` using `makeWrapper`, make it available as a
`serve-docs` package and as the `docs` "app".

This means `nix build .#docs` will build the docs while `nix run .#docs`
will run the server.
2025-05-22 13:48:58 +01:00
github-actions[bot]
5c49988a7c flake/dev/flake.lock: Update
Flake lock file updates:

• Updated input 'treefmt-nix':
    'github:numtide/treefmt-nix/ab0378b61b0d85e73a8ab05d5c6029b5bd58c9fb?narHash=sha256-bo1ptiFoNqm6m1B2iAhJmWCBmqveLVvxom6xKmtuzjg%3D' (2025-05-17)
  → 'github:numtide/treefmt-nix/020cb423808365fa3f10ff4cb8c0a25df35065a3?narHash=sha256-XgxghfND8TDypxsMTPU2GQdtBEsHTEc3qWE6RVEk8O0%3D' (2025-05-22)
2025-05-22 12:17:11 +00:00
github-actions[bot]
b288a5ff89 flake/dev/flake.lock: Update
Flake lock file updates:

• Updated input 'dev-nixpkgs':
    'github:NixOS/nixpkgs/8406224e30c258025cb8b31704bdb977a8f1f009?narHash=sha256-%2B8goyptSXa7qV0k5uPKyky58jpBjI/qkzsbwCZFvhRY%3D' (2025-05-18)
  → 'github:NixOS/nixpkgs/2f9173bde1d3fbf1ad26ff6d52f952f9e9da52ea?narHash=sha256-NnXFQu7g4LnvPIPfJmBuZF7LFy/fey2g2%2BLCzjQhTUk%3D' (2025-05-20)
• Updated input 'home-manager':
    'github:nix-community/home-manager/45c2985644b60ab64de2a2d93a4d132ecb87cf66?narHash=sha256-FZq4/3OtGV/cti9Vccsy2tGSUrxTO4hkDF9oeGRTen4%3D' (2025-05-19)
  → 'github:nix-community/home-manager/2468b2d35512d093aeb04972a1d8c20a0735793f?narHash=sha256-2qAOSixSrbb9l6MI%2BSI4zGineOzDcc2dgOOFK9Dx%2BIY%3D' (2025-05-21)
• Updated input 'nix-darwin':
    'github:lnl7/nix-darwin/b9b927dd1f24094b271e8ec5277a672dc4fc860d?narHash=sha256-GMAJcB8oB9cC%2BTbYTE7QDfw9fwHZyloxUWnUpHnQRko%3D' (2025-05-17)
  → 'github:lnl7/nix-darwin/e2676937faf868111dcea6a4a9cf4b6549907c9d?narHash=sha256-oY/mH8K1LOd%2BYbO58sw9ORtOdTxy3rR9lvTzOJKVUtA%3D' (2025-05-21)
2025-05-22 21:42:03 +10:00
github-actions[bot]
3713ef9e61 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/8406224e30c258025cb8b31704bdb977a8f1f009?narHash=sha256-%2B8goyptSXa7qV0k5uPKyky58jpBjI/qkzsbwCZFvhRY%3D' (2025-05-18)
  → 'github:NixOS/nixpkgs/2f9173bde1d3fbf1ad26ff6d52f952f9e9da52ea?narHash=sha256-NnXFQu7g4LnvPIPfJmBuZF7LFy/fey2g2%2BLCzjQhTUk%3D' (2025-05-20)
2025-05-22 21:42:03 +10:00
Martijn Boers
7e3a0f4e97 plugins/neo-tree: correct contentLayout allowed options
According to the docs, focus is not an accepted value for this field,
it's also a pretty common wish to have tabs layout centered.
2025-05-21 17:45:51 +01:00
Matt Sturgeon
4936f85de3
docs/mdbook: fix user-guide/helpers.html redirect 2025-05-21 14:10:56 +01:00
github-actions[bot]
47dba84e0d flake/dev/flake.lock: Update
Flake lock file updates:

• Updated input 'dev-nixpkgs':
    'github:NixOS/nixpkgs/3fcbdcfc707e0aa42c541b7743e05820472bdaec?narHash=sha256-JBXbjJ0t6T6BbVc9iPVquQI9XSXCGQJD8c8SgnUquus%3D' (2025-05-17)
  → 'github:NixOS/nixpkgs/8406224e30c258025cb8b31704bdb977a8f1f009?narHash=sha256-%2B8goyptSXa7qV0k5uPKyky58jpBjI/qkzsbwCZFvhRY%3D' (2025-05-18)
• Updated input 'home-manager':
    'github:nix-community/home-manager/97118a310eb8e13bc1b9b12d67267e55b7bee6c8?narHash=sha256-B6jmKHUEX1jxxcdoYHl7RVaeohtAVup8o3nuVkzkloA%3D' (2025-05-18)
  → 'github:nix-community/home-manager/45c2985644b60ab64de2a2d93a4d132ecb87cf66?narHash=sha256-FZq4/3OtGV/cti9Vccsy2tGSUrxTO4hkDF9oeGRTen4%3D' (2025-05-19)
2025-05-20 12:16:41 +00:00
github-actions[bot]
d4dff3f6b8 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/3fcbdcfc707e0aa42c541b7743e05820472bdaec?narHash=sha256-JBXbjJ0t6T6BbVc9iPVquQI9XSXCGQJD8c8SgnUquus%3D' (2025-05-17)
  → 'github:NixOS/nixpkgs/8406224e30c258025cb8b31704bdb977a8f1f009?narHash=sha256-%2B8goyptSXa7qV0k5uPKyky58jpBjI/qkzsbwCZFvhRY%3D' (2025-05-18)
2025-05-20 12:16:37 +00:00
Matt Sturgeon
14c7f5f896
dev/tests: add --attr option to print full attrpath of tests
Allows using the `tests` devshell command to discover the full attrpath
of a test.

e.g.

```
$ tests --attr modules-lsp plugins-by-name-lazygit
Printing 2 tests: modules-lsp plugins-by-name-lazygit

Full attr paths:
- checks.x86_64-linux.test-2.entries.modules-lsp
- checks.x86_64-linux.test-18.entries.plugins-by-name-lazygit
```
2025-05-19 20:40:10 +01:00
Matt Sturgeon
f4a7447d27
lib/util: move docs from lib/index to doc-comments
Moved all function-specific docs from `docs/lib/index.md` into RFC145
doc-comments.

Added `lib.nixvim.lua.toLuaObject` to hold the public docs and serve as
a stable impl of `toLua'` in case we decide to change its defaults.
2025-05-19 00:23:21 +01:00
Matt Sturgeon
4a272ca5d7
docs/lib: enable lib.nixvim.lua docs 2025-05-19 00:23:20 +01:00
Matt Sturgeon
bda4be03fc
docs/lib: enable lib.nixvim.utils docs 2025-05-19 00:23:20 +01:00
Matt Sturgeon
5cf8cb5ee6
lib/utils: split into public and internal files
We will include the public file in the docs.
2025-05-19 00:23:20 +01:00
Matt Sturgeon
2ee5d71d52
doc/lib/index.md: update heading title
Move heading to `pages.nix` page title.
2025-05-19 00:22:43 +01:00
Matt Sturgeon
0f8dc108de
docs/man: move FAQ and examples before functions
Like options, function docs are large. Let's put them after the FAQ and
config-examples sections
2025-05-19 00:20:29 +01:00
Matt Sturgeon
83d3535097
docs/man: include all sections from lib-doc 2025-05-19 00:20:29 +01:00
Matt Sturgeon
0c7e2aa96b
docs: user-guide/helpers.mdlib/index.md
Move the user-guide to the new lib reference docs.

Added a MDBook redirect entry.

Updated man docs.
2025-05-19 00:19:57 +01:00
Matt Sturgeon
1c6dd6579a
docs: include function docs
Embed the function reference docs into the main docs website.
2025-05-19 00:19:57 +01:00
Matt Sturgeon
dfaea5982e
docs/lib: init
Generate reference docs for functions that have RFC145 style
doc-comments.

1. function locations

  `docs/lib/function-locations.nix` scans nixvim's extended lib,
  extracting "position entries" via `unsafeGetAttrPos`.

  This is then converted into a nixdoc `locations.json` map of
  "function name" → "markdown location string".

2. mdbook menu

  `docs/lib/menu.nix` renders a mdbook menu representing all page
  entries.

3. markdown pages

  `docs/lib/default.nix` expects a set of "page entries", which come
  from `docs/lib/pages.nix` by default. It passes this data to
  `function-locations.nix` and `menu.nix`, and uses it internally to
  render markdown pages.

  Page entries can contain a `file` to render using `nixdoc`, and also a
  `markdown` attribute which will be included at the top of the docs.

  Additionally, a `title` can be included. This forms the heading
  `$name: $title`, where `name` is derived from the page's attr-path.

  See https://github.com/nix-community/nixdoc
2025-05-19 00:19:56 +01:00
Gaetan Lepage
563fdaeef9 tests: disable papis test on darwin
https://github.com/NixOS/nixpkgs/issues/408528
2025-05-19 00:26:01 +02:00
Gaetan Lepage
98d9c173fc plugins/lsp: mark laravel_ls as unpackaged 2025-05-19 00:26:01 +02:00
github-actions[bot]
54a3864796 generated: Updated lspconfig-servers.json 2025-05-19 00:26:01 +02:00
github-actions[bot]
ab2c391f6a flake/dev/flake.lock: Update
Flake lock file updates:

• Updated input 'dev-nixpkgs':
    'github:NixOS/nixpkgs/eaeed9530c76ce5f1d2d8232e08bec5e26f18ec1?narHash=sha256-ByfPRQuqj%2BnhtVV0koinEpmJw0KLzNbgcgi9EF%2BNVow%3D' (2025-05-12)
  → 'github:NixOS/nixpkgs/12a55407652e04dcf2309436eb06fef0d3713ef3?narHash=sha256-N4cp0asTsJCnRMFZ/k19V9akkxb7J/opG%2BK%2BjU57JGc%3D' (2025-05-16)
• Updated input 'git-hooks':
    'github:cachix/git-hooks.nix/fa466640195d38ec97cf0493d6d6882bc4d14969?narHash=sha256-Wb2xeSyOsCoTCTj7LOoD6cdKLEROyFAArnYoS%2BnoCWo%3D' (2025-05-06)
  → 'github:cachix/git-hooks.nix/80479b6ec16fefd9c1db3ea13aeb038c60530f46?narHash=sha256-2Y53NGIX2vxfie1rOW0Qb86vjRZ7ngizoo%2BbnXU9D9k%3D' (2025-05-16)
• Updated input 'home-manager':
    'github:nix-community/home-manager/7c1cefb98369cc85440642fdccc1c1394ca6dd2c?narHash=sha256-GBZulv50wztp5cgc405t1uOkxQYhSkMqeKLI%2BiSrlpk%3D' (2025-05-14)
  → 'github:nix-community/home-manager/ae755329092c87369b9e9a1510a8cf1ce2b1c708?narHash=sha256-5rCGrnkglKKj4cav1U3HC%2BSIUNJh08pqOK4spQv9RjA%3D' (2025-05-16)
• Updated input 'nix-darwin':
    'github:lnl7/nix-darwin/f88be00227161a1e9369a1d199f452dd5d720feb?narHash=sha256-Ou4zV3OskaDKlkuiM2VT%2B1w/xceXoZ5RRM4ZuW7n5%2BI%3D' (2025-05-13)
  → 'github:lnl7/nix-darwin/8817b00b0011750381d0d44bb94d61087349b6ba?narHash=sha256-4ZVr0x%2Bry6ybym/VhVYACj0HlJo44YxAaPGOxiS88Hg%3D' (2025-05-16)
• Updated input 'treefmt-nix':
    'github:numtide/treefmt-nix/708ec80ca82e2bbafa93402ccb66a35ff87900c5?narHash=sha256-uoQ21EWsAhyskNo8QxrTVZGjG/dV4x5NM1oSgrmNDJY%3D' (2025-05-11)
  → 'github:numtide/treefmt-nix/ab0378b61b0d85e73a8ab05d5c6029b5bd58c9fb?narHash=sha256-bo1ptiFoNqm6m1B2iAhJmWCBmqveLVvxom6xKmtuzjg%3D' (2025-05-17)
2025-05-19 00:26:01 +02:00
github-actions[bot]
d20864c6c7 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/eaeed9530c76ce5f1d2d8232e08bec5e26f18ec1?narHash=sha256-ByfPRQuqj%2BnhtVV0koinEpmJw0KLzNbgcgi9EF%2BNVow%3D' (2025-05-12)
  → 'github:NixOS/nixpkgs/12a55407652e04dcf2309436eb06fef0d3713ef3?narHash=sha256-N4cp0asTsJCnRMFZ/k19V9akkxb7J/opG%2BK%2BjU57JGc%3D' (2025-05-16)
2025-05-19 00:26:01 +02:00
Heitor Augusto
6ef96cb478
plugins/copilot-chat: add curl dependency 2025-05-18 15:27:42 -03:00
Heitor Augusto
928fc1a16f
plugins/copilot-chat: helpers -> lib.nixvim 2025-05-18 15:26:09 -03:00
Heitor Augusto
68dd111eb3
plugins/copilot-chat: remove with lib 2025-05-18 15:23:31 -03:00
Heitor Augusto
5474f9a33f
plugins/copilot-lua: add nodejs dependency and remove nodePackage option 2025-05-17 20:28:20 -03:00
Heitor Augusto
284ce8043b
plugins/copilot-lua: add curl dependency 2025-05-17 20:28:11 -03:00
Heitor Augusto
1deeb7f689
plugins/lsp: add package for luau_lsp 2025-05-17 12:32:21 -03:00
Matt Sturgeon
61c44d7a7f
docs/man: minor cleanup
- Move lua filter to separate file
- Use a subshell to write `nixvim-header.5`
- Use bash function to avoid repetition
2025-05-17 03:30:13 +01:00
Matt Sturgeon
2a4719f275
docs/mdbook: add page ToC
https://github.com/slowsage/mdbook-pagetoc
2025-05-17 02:24:00 +01:00
Matt Sturgeon
ffdeb40a50
flake/dev: sort flake inputs 2025-05-17 00:07:06 +01:00
Matt Sturgeon
0ccc452af2
maintainers: enforce sorting 2025-05-17 00:07:06 +01:00
Matt Sturgeon
0a6bd171cf
flake: add keep-sorted to treefmt 2025-05-17 00:07:06 +01:00
Matt Sturgeon
2628efee71
flake/devshell: add treefmt to shell 2025-05-16 04:29:34 +01:00
Matt Sturgeon
4c989abc8c
flake/devshell: run treefmt directly in format command
This is much faster than running `nix fmt`.

Running treefmt directly will use the treefmt installed in the current
shell. Running `nix fmt` will first re-evaluate the flake.
2025-05-16 04:29:34 +01:00
Matt Sturgeon
46e1359338
flake: use pre-configured treefmt package in git-hooks 2025-05-16 04:05:42 +01:00
github-actions[bot]
95ca65c8d1 flake/dev/flake.lock: Update
Flake lock file updates:

• Updated input 'home-manager':
    'github:nix-community/home-manager/8d832ddfda9facf538f3dda9b6985fb0234f151c?narHash=sha256-NnPzzXEqfYjfrimLzK0JOBItfdEJdP/i6SNTuunCGgw%3D' (2025-05-13)
  → 'github:nix-community/home-manager/7c1cefb98369cc85440642fdccc1c1394ca6dd2c?narHash=sha256-GBZulv50wztp5cgc405t1uOkxQYhSkMqeKLI%2BiSrlpk%3D' (2025-05-14)
2025-05-14 12:16:07 +00:00
FKouhai
1c53ad9b2f
plugins/timerly: init 2025-05-13 23:50:02 +02:00
Gaetan Lepage
d385972711 Revert "tests/lsp: disable ols test because odin is broken"
This reverts commit 6597afe209.
2025-05-13 21:30:47 +00:00
github-actions[bot]
64880922bd flake/dev/flake.lock: Update
Flake lock file updates:

• Updated input 'dev-nixpkgs':
    'github:NixOS/nixpkgs/b3582c75c7f21ce0b429898980eddbbf05c68e55?narHash=sha256-FshoQvr6Aor5SnORVvh/ZdJ1Sa2U4ZrIMwKBX5k2wu0%3D' (2025-05-07)
  → 'github:NixOS/nixpkgs/eaeed9530c76ce5f1d2d8232e08bec5e26f18ec1?narHash=sha256-ByfPRQuqj%2BnhtVV0koinEpmJw0KLzNbgcgi9EF%2BNVow%3D' (2025-05-12)
• Updated input 'home-manager':
    'github:nix-community/home-manager/fb061f555f821fe4fb49f8f6f2a0cc3d5728bd52?narHash=sha256-IDsM/9/tHQBlhG3tXI2fTM84AUN1uRa7JDPT1LMlGes%3D' (2025-05-12)
  → 'github:nix-community/home-manager/8d832ddfda9facf538f3dda9b6985fb0234f151c?narHash=sha256-NnPzzXEqfYjfrimLzK0JOBItfdEJdP/i6SNTuunCGgw%3D' (2025-05-13)
• Updated input 'nix-darwin':
    'github:lnl7/nix-darwin/6cb36e8327421c61e5a3bbd08ed63491b616364a?narHash=sha256-GeC99gu5H6%2BAjBXsn5dOhP4/ApuioGCBkufdmEIWPRs%3D' (2025-05-08)
  → 'github:lnl7/nix-darwin/f88be00227161a1e9369a1d199f452dd5d720feb?narHash=sha256-Ou4zV3OskaDKlkuiM2VT%2B1w/xceXoZ5RRM4ZuW7n5%2BI%3D' (2025-05-13)
2025-05-13 21:30:23 +00:00
github-actions[bot]
fcd3accd34 flake.lock: Update
Flake lock file updates:

• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/b3582c75c7f21ce0b429898980eddbbf05c68e55?narHash=sha256-FshoQvr6Aor5SnORVvh/ZdJ1Sa2U4ZrIMwKBX5k2wu0%3D' (2025-05-07)
  → 'github:NixOS/nixpkgs/eaeed9530c76ce5f1d2d8232e08bec5e26f18ec1?narHash=sha256-ByfPRQuqj%2BnhtVV0koinEpmJw0KLzNbgcgi9EF%2BNVow%3D' (2025-05-12)
2025-05-13 21:30:19 +00:00
Matt Sturgeon
cbd5f7de5e
modules/lsp/onAttach: fix bufnr and document event arg
`:h event-args`: https://neovim.io/doc/user/api.html#event-args
`:h LspAttach`: https://neovim.io/doc/user/lsp.html#LspAttach

Fixes #3319
2025-05-13 18:45:00 +01:00
Farid Zakaria
ff0ccdf572
docs: add note on "following" nixpkgs input (#3317)
The use of `follows` in a flake can cause issues even when `useGlobalPackages` is disabled.

Highlight this in the doc.
2025-05-12 21:58:54 +01:00
Stanislav Asunkin
49a7bb573a modules/top-level: change usages of import to callPackage 2025-05-12 17:39:01 +03:00
Stanislav Asunkin
4c23fb2738 tests/modules/performance/combine-plugins: use shared stub plugins
This commit replaces stub plugins with the shared ones from utils
module.
This also removes separate tests for checking python and lua
dependencies. This is now tested in the 'default' test thanks to
`pluginChecks` code.
2025-05-12 17:39:01 +03:00
Stanislav Asunkin
a49b270861 tests/modules/performance/byte-compile-lua: use shared stub plugins
This commit finalizes using shared utils stub plugins for
performance.byteCompileLua tests.
To re-use more code from utils module, 'pluginChecksFor', 'libChecksFor'
and 'pythonChecksFor' functions were introduced. These functions
generate a check code for the given plugins/libs names.
2025-05-12 17:39:01 +03:00