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

Remove build_project and use builtin lua in neovim #127

Merged
merged 6 commits into from
Aug 26, 2024

Conversation

JafarAbdi
Copy link
Owner

@JafarAbdi JafarAbdi commented Aug 26, 2024

Summary by Sourcery

Remove the 'build_project.py' script and integrate file execution directly into Neovim using Lua. Add snippet support and enhance installation scripts to support macOS. Update plugin lock file with new commits.

New Features:

  • Introduce a new runner system in Neovim configuration to handle file execution based on file type, supporting Python, Bash, Fish, XML, and Lua.
  • Add snippet support in Neovim with predefined snippets for various file types including C++ and CMake.

Enhancements:

  • Refactor the Neovim configuration to replace the external 'build_project.py' script with built-in Lua functionality for running files.
  • Enhance the installation scripts to support macOS for GitHub CLI, WezTerm, and StyLua installations.

Chores:

  • Update the lazy-lock.json file to reflect new commits for various plugins including lazy.nvim, nvim-cmp, and nvim-dap.

Copy link
Contributor

sourcery-ai bot commented Aug 26, 2024

Reviewer's Guide by Sourcery

This pull request removes the build_project.py script and replaces it with built-in Lua functions in Neovim. It also adds support for custom snippets, updates the installation process for some tools, and makes minor changes to the Neovim configuration.

File-Level Changes

Change Details Files
Replace external build_project.py script with built-in Lua runners
  • Remove build_project.py script
  • Add a table of Lua runner functions for different file types
  • Update run_file function to use the new Lua runners
  • Remove unnecessary root directory detection logic
neovim/.config/nvim/init.lua
scripts/.local/bin/build_project.py
Add support for custom snippets in Neovim
  • Create a table of snippets for different file types
  • Implement a custom completion source for snippets
  • Register the new snippets source with nvim-cmp
neovim/.config/nvim/init.lua
Update installation process for various tools
  • Add macOS support for installing gh CLI
  • Update WezTerm installation process for macOS
  • Update StyLua installation process for macOS
fish/conf.d/installs.fish
Minor updates to Neovim configuration
  • Update lazy-lock.json with new plugin versions
  • Remove unused functions from build_project.py
neovim/.config/nvim/lazy-lock.json
scripts/.local/bin/build_project.py

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • Continue your discussion with Sourcery by replying directly to review comments.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey @JafarAbdi - I've reviewed your changes - here's some feedback:

Overall Comments:

  • The changes look good overall, but we noticed that the rust and cpp runners from the original build_project.py script are not present in the new Lua configuration. Is there a plan to add these back, or are they no longer needed?
Here's what I looked at during the review
  • 🟡 General issues: 3 issues found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

neovim/.config/nvim/init.lua Show resolved Hide resolved
neovim/.config/nvim/init.lua Outdated Show resolved Hide resolved
neovim/.config/nvim/init.lua Outdated Show resolved Hide resolved
@JafarAbdi JafarAbdi merged commit 5ff6889 into main Aug 26, 2024
2 checks passed
@JafarAbdi JafarAbdi deleted the refactor/build_project branch August 26, 2024 14:30
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.

1 participant