Commit Graph

189 Commits

Author SHA1 Message Date
Folke Lemaitre 60cf258a9a
fix(docs): always update helptags for local plugins 2024-11-10 07:28:51 +01:00
Lorenzo Zabot 40dab7450e
style(typos): correct a few typos (#1776)
## Description

<!-- Describe the big picture of your changes to communicate to the
maintainers
  why we should accept this pull request. -->
This PR just fixes a few typos :)

`dont => don't`
## Related Issue(s)

<!--
  If this PR fixes any issues, please link to the issue here.
  - Fixes #<issue_number>
-->

## Screenshots

<!-- Add screenshots of the changes if applicable. -->
2024-10-22 12:43:33 +02:00
Alexander Grebennik 7108809ab1
fix(plugins): "Vim:E150: Not a directory" on plugin update (#1679)
## Description

On plugins update it fails with following error for any plugin.

```
~/.local/share/nvim/lazy/lazy.nvim/manage/task/plugin.lua:95: Vim:E150: Not a directory: ~/.local/share/nvim/lazy/gitsigns.nvim/doc/
```
2024-07-25 12:53:01 +02:00
Folke Lemaitre d5686efbd0
feat: added `opts.git.cooldown` to allow updating plugins on slow connections. Fixes #1656 2024-07-23 13:31:25 +02:00
Folke Lemaitre 5bdb12a038
fix(build): only load the plugin before build for `:` build commands 2024-07-19 08:57:37 +02:00
Folke Lemaitre d731a6b005
feat(git): added git network throttle to limit network related git ops per interval. Closes #1635 2024-07-16 16:50:31 +02:00
Ethan Wu 7ed9f7173c
fix(lockfile): ensure newline at EOF for lockfile (#1639)
## Description

The lockfile currently does not end with a newline at EOF. Text files
should [end with a newline](https://unix.stackexchange.com/a/18789).
This also lets you manually edit the lockfile in vim without 'fixeol'
creating a spurious change for the added newline.

This change however will create a change in users' lockfiles adding a
newline upon updating, but since the lockfile would be changing anyways
to update lazy.nvim itself, this is likely acceptable.

## Related Issue(s)

*none*

## Screenshots

*N/A*
2024-07-13 09:51:44 +02:00
Folke Lemaitre f0324defdd
fix(rocks): try building anyway even when prerequisits have not been met. (will likely fail) 2024-07-08 07:45:45 +02:00
Andre Toerien 72c0dc9462
fix(git): local plugin fixes (#1624)
## Description

As I described in
https://github.com/folke/lazy.nvim/pull/1512#issuecomment-2212474372,
this makes it so that local plugins will only show as needing updates if
the local branch is behind the upstream branch. This is done by checking
the output of the `git log` command, and only setting `plugin._.updates`
if the output is not empty.

This seems to solve my issue where local plugins with unpushed changes
always show as needing updates, but if there's a easier/better way of
doing it then please feel free to edit/close this. Or if you don't agree
that the current behaviour is a bug, then that's also fine - it's not a
big deal and I can easily just ignore the "updates available" notice.

I also came across a minor issue where the plugin diff view (press `d`)
compares the wrong commits for local plugins, because
[lua/lazy/view/init.lua](c771cf4928/lua/lazy/view/init.lua (L268))
always uses `get_target`. I fixed this by moving `get_local_target` into
`get_target` - I think this is simpler and more straightforward than the
alternative of adding a ternary everywhere `get_target` is called.

This second bugfix is a very small change, so I've just included it
here, but I'm happy to make a second PR if you'd like.

## Related Issue(s)

Related PR: #1512
2024-07-07 17:13:49 +02:00
Folke Lemaitre 81d2bfffdc
fix(git): only check for new commits for local plugins. Closes #1512 2024-07-07 08:42:21 +02:00
Folke Lemaitre baac551777
fix(lockfile): keep cond=false and enabed=false in lockfile. Fixes #1535. Fixes #1606 2024-07-05 09:01:04 +02:00
Folke Lemaitre 1fad61712b
fix(async): make asyncs abortable 2024-06-30 13:35:14 +02:00
Folke Lemaitre 2f4ac035bc
perf: suspend when tasks are active 2024-06-30 09:13:04 +02:00
Folke Lemaitre c7ed87f9ca
perf: automatically suspend the scheduler when all threads are waiting (#1591)
* perf: automatically suspend the scheduler when all threads are waiting

* ci: fix ci

* test: cleanup
2024-06-30 08:48:03 +02:00
Folke Lemaitre a75d950b8f
fix(process): deal with process errors 2024-06-29 13:52:50 +02:00
Folke Lemaitre 9cf745939d
feat(task): build procs can now yield a LazyMsg for more control 2024-06-28 20:17:35 +02:00
Folke Lemaitre 2a6a2dce1b
fix(git): tagrefs 2024-06-28 18:31:12 +02:00
Folke Lemaitre ab46edbd47
perf: async render 2024-06-28 17:44:21 +02:00
Folke Lemaitre a36ebd2a75
refactor: async processes 2024-06-28 16:08:26 +02:00
Folke Lemaitre 60fe75c88d
fix(task): run on_exit async. See #1569 2024-06-28 00:35:41 +02:00
Folke Lemaitre 461552474c
refactor: cleanup 2024-06-28 00:35:40 +02:00
Folke Lemaitre 68cee30cdb
perf: prevent active waiting in coroutines. suspend/resume instead 2024-06-27 13:06:39 +02:00
Folke Lemaitre 82276321f5
fix(rocks): if installing with luarocks (binaries) fails, then build from source. Fixes #1563 2024-06-27 11:33:11 +02:00
Folke Lemaitre e02c5b1b57
fix(runner): only check for errors when a task is no longer running 2024-06-27 11:32:30 +02:00
Folke Lemaitre a0391c3e21
fix(manage): dont skip install for plugins that need a build, but dont have an url (like local plugins). Fixes #1563 2024-06-27 11:32:00 +02:00
Folke Lemaitre 591ded8309
feat(ui): keep cursor position when rendering view 2024-06-26 22:45:21 +02:00
Folke Lemaitre 249902ab31
fix(ui): diagnostics without status 2024-06-26 22:44:57 +02:00
Folke Lemaitre a0a51c06c2
feat: added `opts.headless` to control ansi output when running headless 2024-06-26 21:38:28 +02:00
Folke Lemaitre 93b3a77286
fix(runner): wait_step 2024-06-26 20:17:32 +02:00
Folke Lemaitre 66a4170f0e
fix(runner): properly do concurrency 2024-06-26 19:58:45 +02:00
Folke Lemaitre 97f4df0824
fix(runner): only use Config.plugins when updated. Fixes #1560 2024-06-26 19:39:28 +02:00
Folke Lemaitre 56075b57c4
fix(runner): bring concurrency back 2024-06-26 18:45:40 +02:00
Folke Lemaitre 206d208018
test: fix tests 2024-06-26 18:42:52 +02:00
Folke Lemaitre 6c7ef7e27a
refactor: logging 2024-06-26 18:31:31 +02:00
Folke Lemaitre 765773a176
refactor: use new async code for runner and simplify task class 2024-06-26 17:06:56 +02:00
Folke Lemaitre 768de1ebf6
refactor: move scheduler to async 2024-06-26 15:11:31 +02:00
Folke Lemaitre bbe136bda6
test: fix tests 2024-06-26 14:30:38 +02:00
Folke Lemaitre 0614ca6ca6
perf: tasks are now fully async 2024-06-26 14:28:53 +02:00
Folke Lemaitre 28e435b7f3
fix(git): fetch commit from origin or local to check if branch was changed. See #1549 2024-06-26 07:15:12 +02:00
Folke Lemaitre b6eba0d026
ci: auto-get rockspec mappings for rock name => github short url or url 2024-06-25 17:41:16 +02:00
Folke Lemaitre 7d3f69104f
fix(rocks): better errors / warnings when something goes wrong with luarocks 2024-06-25 13:23:25 +02:00
Folke Lemaitre 45cd8d3f0f
fix(rocks): hererocks paths on windows 2024-06-25 06:40:50 +02:00
Folke Lemaitre d87da76679
feat(rocks): use hererocks to install luarocks when luarocks is not found 2024-06-25 07:55:30 +02:00
Folke Lemaitre 77edda11bf
test: fixes 2024-06-24 19:55:11 +02:00
Folke Lemaitre 105d4805ad
fix(runner): sync package specs after installing and before building 2024-06-24 19:38:33 +02:00
Folke Lemaitre b73c57ed9e fix(luarocks): cleanup luarocks when deleting a plugin 2024-06-24 17:15:10 +02:00
Folke Lemaitre 368747bc9a feat(build): build files and functions are now async. use coroutine.yield to interrupt and report progress 2024-06-24 17:15:10 +02:00
Folke Lemaitre fcfd54835d feat: spec.rocks is no longer needed & added support for installing any luarock 2024-06-24 17:15:10 +02:00
Folke Lemaitre 3be55a4615 feat: added support for plugin packages by lazy, rockspec and packspec 2024-06-24 17:15:10 +02:00
Folke Lemaitre f1ba2e3d05 feat: luarocks support 2024-06-24 17:15:10 +02:00