Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: external sync actions not running #469

Merged
merged 1 commit into from
Jul 9, 2024

Conversation

austinliuigi
Copy link
Contributor

This bug was introduced by the refactor in commit 704940f, which changed external_actions from a list to a key-value table. However, when iterating through external_actions, we still use ipairs which results in no values.

This caused rocks-git to not run sync actions on any of its rocks, so e.g. adding fzf-lua = { git = "ibhagwan/fzf-lua" } to your rocks.toml then running :Rocks sync would not actually install fzf-lua.

Note

On my machine, rocks-git properly installs its rocks after a fresh bootstrap of rocks.nvim and an initial :Rocks sync, but I'm not sure why it works on the first run. After that, rocks-git doesn't run its sync callback due to the bug this PR fixes.

This bug was introduced by the refactor in commit 704940f,
which changed external_actions from a list to a key-value table.
However, when iterating through external_actions, we still use ipairs
which results in no values. The fix is to use pairs, which properly
iterates through all external_actions.
Copy link
Contributor

github-actions bot commented Jul 9, 2024

Review Checklist

Does this PR follow the Contribution Guidelines? Following is a partial checklist:

Proper conventional commit scoping:

  • For example, fix(installer): some installer bugfix

  • Pull request title has the appropriate conventional commit prefix.

If applicable:

  • Tested
    • Tests have been added.
    • Tested manually (steps in PR description).
  • Updated documentation.

Copy link
Member

@mrcjkb mrcjkb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, good catch!

Thanks for the fix 🙏

@mrcjkb mrcjkb enabled auto-merge (squash) July 9, 2024 21:58
@mrcjkb mrcjkb merged commit 235c7df into nvim-neorocks:master Jul 9, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants