Skip to content

Search through Neovimcraft.com's curated list of neovim plugins, using telescope.nvim

License

Notifications You must be signed in to change notification settings

janwvjaarsveld/neovimcraft.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Neovimcraft.nvim

Neovimcraft.nvim is a Neovim plugin designed to simplify the process of discovering and exploring plugins from the nvim.sh API (see neurosnap/neovimcraft). It integrates seamlessly with Telescope.nvim, offering an intuitive interface for plugin and tag searches.

Disclaimer

This plugin is not an official plugin for neovimcraft.com. It is an independent project that utilizes the publicly available API from neovimcraft.com to fetch and display plugin data. Special thanks to the team behind neovimcraft.com for providing such an excellent resource for the Neovim community and making this API available.

Table of Contents

Features

  • Search for plugins by name or tag.
  • View detailed information about plugins, including stars, forks, and descriptions.
  • Preview plugin README files in a floating window.
  • Explore available tags to refine your searches.

Requirements

Optional dependencies:

Installation

Use your preferred plugin manager to install neovimcraft.nvim. For example:

use {
    'janwvjaarsveld/neovimcraft.nvim',
    requires = { 'nvim-telescope/telescope.nvim', 'nvim-lua/plenary.nvim' },
}
return {
    'janwvjaarsveld/neovimcraft.nvim',
    dependencies = { 'nvim-telescope/telescope.nvim', 'nvim-lua/plenary.nvim' },
    -- Calling setup is not required if you are happy with the default configuration
    config = function()
        require('neovimcraft').setup({
            -- Add your custom configuration here
        })
    end
}

Configuration

You can configure neovimcraft.nvim by passing a table to the setup function. Below is the default configuration:

require('neovimcraft').setup({
    -- Path to store the cache. Data will be stored in a subdirectory called 'neovimcraft'
    cache_path = vim.fn.stdpath("cache"),
    -- If true, the cache will be checked and updated when the plugin is loaded
    -- If false, the cache will be checked and updated on the first search
    update_cache_at_startup = false,
    -- Enable or disable glow for README rendering
    use_glow = true,
    -- The window configuration for the readme preview
    readme_window = {
        -- The fraction of the editor's width
        width_ratio = 0.6,
        -- The fraction of the editor's height
        height_ratio = 0.8,
        -- Available options: 'none', 'single', 'double', 'rounded', etc.
        border = "double",
    },
    -- Enable or disable user auto commands
    setup_user_autocmds = true,
    -- User command name
    command_names = {
        -- Command for plugin search
        search_plugins = "NeovimcraftPlugins",
        -- Command for tag search
        search_tags = "NeovimcraftTags",
    },
    key_bindings = {
        -- Key to close the preview window
        close = "q",
        -- Key to open GitHub link
        open_git = "o",
        -- Key to go back to search results
        back_to_search = "<BS>",
    },
    -- How often to refresh the cache in seconds
    cache_refesh_rate = 24 * 3600, -- 24 hours
})

Commands

If setup_user_commands is enabled, the following user autocommands are available (unless you've customized the command names):

  • :NeovimcraftPlugins – Search all plugins.
  • :NeovimcraftTags – Search all tags.

Usage

The plugin supports two different ways to render README files:

  • If you have glow installed on your system, README files will be rendered with terminal markdown formatting for an enhanced viewing experience
  • If glow is not available, the plugin will fallback to using your configured markdown LSP for syntax highlighting

You can search for plugins in several ways:

  1. Basic search:

    :NeovimcraftPlugins  " Search all plugins available using Telescope
    :NeovimcraftTags     " Search all tags available using Telescope
  2. Filtered search with arguments:

    :NeovimcraftPlugins lazy             " Search for plugins containing `lazy` as part of the `author/repo_name`
    :NeovimcraftPlugins folke/lazy.nvim  " Will open the plugin README in a floating window
    :NeovimcraftTags format              " Search for plugins with the `format` tag
    :NeovimcraftTags comp                " Search tags with `comp` as the filter input
  3. Using Telescope extension:

    require('telescope').load_extension('neovimcraft')

    You can then use the following Telescope functions:

    :Telescope neovimcraft plugins   " Search all plugins available using Telescope
    :Telescope neovimcraft tags      " Search all tags available using Telescope
  4. Select a plugin to view its details in a floating window.

  5. In the floating window:

    • Press q to close the window.
    • Press o to open the plugin’s GitHub page.
    • Press <BS> to navigate back to the previous Telescope window.

Contributing

Feel free to contribute by submitting issues, feature requests, or pull requests. Ensure code follows best practices and is well-documented.

I don't see my plugin in the search results

If you don't see your plugin in the search results, it may be that the plugin is not yet submitted to neovimcraft.com. You can submit your plugin by following the instructions here

Credits


Enjoy discovering awesome Neovim plugins with Neovimcraft.nvim! 🚀

About

Search through Neovimcraft.com's curated list of neovim plugins, using telescope.nvim

Topics

Resources

License

Stars

Watchers

Forks

Languages