Thanks to visit codestin.com
Credit goes to github.com

Skip to content

vasigorc/vasile-lazyvim-config

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

111 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

💤 LazyVim

A starter template for LazyVim. Refer to the documentation to get started.

Prerequisuites

There are two approaches for installing the prerquisites. You may pick either or a combination of both

Requirements for manual installation

Please see installation requirements for LazyVim here. For installation of Neovim (>= version 0.9.0) refer to their installation guide

Additional recommendations / recommendations

  • nvim
  • lazygit
  • rustup
    • [Optional for Rust] Run rustup component add rust-analyzer
  • go
  • pipx
  • fd
  • [Optional: if you want to avoid errors having images in Markdown files] imagemagick
  • [Optional: for Scala] NeoVm will configure metals for you, but you will have to manually install metals when on a *.scala file with :MetalsInstall
  • [Optional: for Protocol-Buffers] install protols plugin. Make sure that you have cargo version 1.88.0 installed. This plugin requires edition2024. I used rustup's `nightly toolchain'.
  • [Optional: for Go] Install Go CI linter to avoid anoying warnings:
go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
  • [Optional: for SQL] Install SQL tooling for PostgreSQL-aware formatting and database connections:
# PostgreSQL-aware SQL formatter and linter
pipx install sqlfluff

# PostgreSQL client for database connections
sudo apt install postgresql-client

# Optional: SQL LSP server for enhanced intelligence
go install github.com/sqls-server/sqls@latest
  • [Optional: for Ruby] Install Ruby via rbenv and required gems:
# Install rbenv and ruby-build (don't use apt install rbenv - it's outdated)
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build

# Add to ~/.zshrc (or ~/.bashrc)
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.zshrc
echo 'eval "$(rbenv init - zsh)"' >> ~/.zshrc
source ~/.zshrc

# Install Ruby (check latest 3.4.x version with: rbenv install -l | grep ^3.4)
rbenv install 3.4.8
rbenv global 3.4.8

# Install required gems
gem install rubocop sonargraph

Running inside nix-shell

Nix is a package management tool for reproducible development environments.

Make sure that you have Nix installed, by following the instruction steps here.

Clone this repository and follow README steps in its nix directory.

For most basic Neovim setup you may run nvim inside nix-shell like such:

~/$PATH_TO_CLONED_REPO/bash-utils/nix/dynamic-nix-shell.sh nvim

Then you can add more modules following nvim in the previous command like python depending on your current project.

How to use this setup

Make sure that you have your prerequistes and then follow the steps from this page.

CodeCompanion with Ollama

This LazyVim configuration integrates with CodeCompanion.nvim to provide AI-powered coding assistance. By default, it is configured to use Ollama with the qwen3:14b model, which is a cost-efficient (free) solution for local AI inference.

Ollama Installation and Model Setup

To use CodeCompanion with Ollama, you need to install Ollama and download the qwen3:14b model.

For Linux (Debian-based):

  1. Install Ollama:

    curl -fsSL https://ollama.com/install.sh | sh
  2. Download the qwen3 model:

    ollama pull qwen3:14b

For macOS:

  1. Install Ollama: Download the macOS application from ollama.com/download and follow the installation instructions.

  2. Download the qwen3 model:

    ollama pull qwen3:14b

Switching to Other Models

The default model for CodeCompanion is qwen3:14b due to its cost-effectiveness. However, you can easily switch to other models supported by Ollama or other adapters (e.g., OpenAI, DeepSeek, Anthropic) by modifying the lua/plugins/codecompanion.lua file.

To change the default model for Ollama, locate the ollama_qwen adapter definition and modify the model field:

        ollama_qwen = function()
          return require("codecompanion.adapters").extend("ollama", {
            name = "ollama_qwen",
            schema = {
              model = {
                default = "qwen3:14b", -- Change 'qwen3:14b' to your desired Ollama model
              },
            },
          })
        end,

To switch to a different adapter (e.g., OpenAI), you would modify the interactions section:

      interactions = {
        chat = { adapter = "openai" }, -- Change 'ollama_qwen' to 'openai' or another configured adapter
        inline = { adapter = "openai" },
        agent = { adapter = "deepseek" },
      },

Remember to set the corresponding API key as an environment variable if you are using a paid service like OpenAI, DeepSeek, or Anthropic. For example, for OpenAI, set OPENAI_API_KEY.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages