cord-nvim 2.3.16

🚀 The most extensible Discord Rich Presence plugin for Neovim, powered by Rust.
<div align="center">
  <h1>🧩 <strong>Cord</strong> – Tailor Your Presence Like Never Before</h1>
  <div>
    <a href="https://github.com/vyfor/cord.nvim/stargazers"><img src="https://img.shields.io/github/stars/vyfor/cord.nvim?style=for-the-badge&color=8281f3&labelColor=242529&logo=data:image/svg%2bxml;base64,PHN2ZyB3aWR0aD0iODAwcHgiIGhlaWdodD0iODAwcHgiIGZpbGw9Im5vbmUiIHZpZXdCb3g9IjAgMCAyNCAyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJtMTEuMDc1IDMuMjU1OGMwLjMzOTMtMC44MjczOCAxLjUxMTEtMC44MjczOCAxLjg1MDQgMGwxLjcyNDEgNC4yMDM3YzAuMTQzNyAwLjM1MDI0IDAuNDcyOCAwLjU4OTM0IDAuODUwMiAwLjYxNzcybDQuNTMwOCAwLjM0MDcxYzAuODkxNyAwLjA2NzA2IDEuMjUzOCAxLjE4MTQgMC41NzE4IDEuNzU5OGwtMy40NjUyIDIuOTM4OGMtMC4yODg3IDAuMjQ0OC0wLjQxNDQgMC42MzE3LTAuMzI0NyAwLjk5OTVsMS4wNzYgNC40MTQzYzAuMjExOCAwLjg2ODgtMC43MzYyIDEuNTU3NS0xLjQ5NyAxLjA4NzZsLTMuODY1Ny0yLjM4NzVjLTAuMzIyMS0wLjE5ODktMC43Mjg5LTAuMTk4OS0xLjA1MSAwbC0zLjg2NTcgMi4zODc1Yy0wLjc2MDg1IDAuNDY5OS0xLjcwODgtMC4yMTg4LTEuNDk3LTEuMDg3NmwxLjA3Ni00LjQxNDNjMC4wODk2NS0wLjM2NzgtMC4wMzYwNS0wLjc1NDctMC4zMjQ3Ni0wLjk5OTVsLTMuNDY1Mi0yLjkzODhjLTAuNjgyMDItMC41NzgzOC0wLjMxOTk0LTEuNjkyOCAwLjU3MTgxLTEuNzU5OGw0LjUzMDgtMC4zNDA3MWMwLjM3NzQ4LTAuMDI4MzggMC43MDY1OC0wLjI2NzQ4IDAuODUwMjItMC42MTc3MmwxLjcyNDEtNC4yMDM3eiIgc3Ryb2tlPSIjODI4MWYzIiBzdHJva2Utd2lkdGg9IjIiLz48L3N2Zz4=" alt="Stargazers"></a>
    <a href="https://neovim.io/"><img src="https://img.shields.io/badge/Neovim-%20%3E%3D%200.6.0-ffffff?style=for-the-badge&logo=neovim&color=8281f3&labelColor=242529&logoColor=8281f3" alt="Neovim Logo"></a>
    <a href="https://github.com/vyfor/cord.nvim/forks"><img src="https://img.shields.io/github/forks/vyfor/cord.nvim?style=for-the-badge&color=8281f3&labelColor=242529&logo=data:image/svg%2bxml;base64,PHN2ZyBmaWxsPSIjODI4MWYzIiB2aWV3Qm94PSItNCAtMiAyNCAyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNOCAxOGExIDEgMCAxIDAgMC0yIDEgMSAwIDAgMCAwIDJ6bTEuMDMzLTMuODE3QTMuMDAxIDMuMDAxIDAgMSAxIDcgMTQuMTd2LTEuMDQ3YzAtLjA3NC4wMDMtLjE0OC4wMDgtLjIyMWExIDEgMCAwIDAtLjQ2Mi0uNjM3TDMuNDYgMTAuNDJBMyAzIDAgMCAxIDIgNy44NDVWNS44MjlhMy4wMDEgMy4wMDEgMCAxIDEgMiAwdjIuMDE2YTEgMSAwIDAgMCAuNDg3Ljg1OGwzLjA4NiAxLjg0NmEzIDMgMCAwIDEgLjQ0My4zMjQgMyAzIDAgMCAxIC40NDQtLjMyNGwzLjA4Ni0xLjg0NmExIDEgMCAwIDAgLjQ4Ny0uODU4VjUuODQxQTMuMDAxIDMuMDAxIDAgMCAxIDEzIDBhMyAzIDAgMCAxIDEuMDMzIDUuODE3djIuMDI4YTMgMyAwIDAgMS0xLjQ2IDIuNTc1bC0zLjA4NiAxLjg0NmExIDEgMCAwIDAtLjQ2Mi42MzdjLjAwNS4wNzMuMDA4LjE0Ny4wMDguMjJ2MS4wNnpNMyA0YTEgMSAwIDEgMCAwLTIgMSAxIDAgMCAwIDAgMnptMTAgMGExIDEgMCAxIDAgMC0yIDEgMSAwIDAgMCAwIDJ6Ii8+PC9zdmc+" alt="Forks"></a>
  </div>
  <br/>
  <img src="https://github.com/user-attachments/assets/8e684058-f3ea-4010-817e-529b47730abb" alt="Cord Logo" width="200px">
  <h3>🚀 The most extensible Discord Rich Presence plugin for Neovim, powered by Rust.
  </h3>
  <img src="https://github.com/user-attachments/assets/df73221e-565b-49e5-9dad-1c60aed6f9c3" alt="Cord Banner">
</div>

<div align="center">
  <div><a href="https://discord.gg/q9rC4bjCHv"><img src="https://discord.com/api/guilds/1322899307925602366/widget.png?style=banner2" alt="cord.nvim"/></a></div>
</div>

<div align="center">
  <a href="#-installation">Installation</a>
  <span> • </span>
  <a href="https://github.com/vyfor/cord.nvim/wiki">Documentation</a>
  <span> • </span>
  <a href="https://discord.gg/q9rC4bjCHv">Discord</a>
</div>

> [!IMPORTANT]
> Cord no longer requires Rust to be installed. Server component will be automatically downloaded from GitHub Releases.

## 💎 Features
- ⚡ Fast, lightweight, and batteries included.
- 🚀 [Rate-limit](https://github.com/vyfor/cord.nvim/wiki/FAQ#q-rich-presence-updates-take-a-long-time-to-appear-in-discord-why) aware, event-driven architecture.
- 🎨 Dynamic string templates with custom variables.
- 🗃️ Customizable assets for any file/buffer type.
- 🔧 Flexible configuration with rich API, function-based fields, hooks, user commands and custom IPC paths.
- 🔌 Plugin system of its own, with many plugins out-of-the-box.
- 🛠️ Finds repositories and workspaces based on VCS files without relying on command-line tools.
- 🧠 Manages activities across all instances with a single connection to Discord.
- 💤 Detects when you're idle and switches to the most recent active instance.
- 🎯 [Async](https://github.com/vyfor/cord.nvim/wiki/Async)-first design with an async-aware configuration layer.
- 📦 Works with different Discord setups (Snap, Flatpak, [WSL](https://github.com/vyfor/cord.nvim/wiki/Special-Environments#-running-inside-wsl), and even the [~~browser~~](https://github.com/vyfor/cord.nvim/wiki/Special-Environments#-using-discord-in-a-browser)).
- 🌍 Runs on Windows, Linux, macOS, and FreeBSD.
- 🌸 Includes 120+ icons for 200+ file types and plugins, featured in distinct themes and flavors.
- 🔁 Reconnects automatically if connection to Discord is lost.

## 📦 Installation

> [!NOTE]
> **cord.nvim** will automatically load with defaults; calling `setup()` is optional.
> The default configuration is found [here](https://github.com/vyfor/cord.nvim/wiki/Configuration#%EF%B8%8F-default-configuration).

<details>
<summary><strong>lazy.nvim</strong></summary>

```lua
{
  'vyfor/cord.nvim'
}
```

> #### ⚙️ Configuring
> ```lua
> {
>   'vyfor/cord.nvim',
>   opts = {
>     -- ...
>   }
> }
> ```

</details>

<details>
<summary><strong>packer.nvim</strong></summary>

```lua
use {
  'vyfor/cord.nvim'
}
```

> #### ⚙️ Configuring
> ```lua
> use {
>   'vyfor/cord.nvim',
>   config = function()
>     require('cord').setup {
>       -- ...
>     }
>   end
> }
> ```

</details>

<details>
<summary><strong>rocks.nvim</strong></summary>

Cord is available on [LuaRocks](https://luarocks.org/modules/vyfor/cord.nvim).

```vim
:Rocks install cord.nvim
```

> #### ⚙️ Configuring
> ```lua
> require('cord').setup {
>   -- ...
> }
> ```

</details>

<details>
<summary><strong>vim.pack (v0.12+)</strong></summary>

```lua
vim.pack.add { 'https://github.com/vyfor/cord.nvim' }
```

**Configuring:**

> #### ⚙️ Configuring
> ```lua
> require('cord').setup {
>   -- ...
> }
> ```

</details>

<details>
<summary><strong>Vim packages</strong></summary>

**Unix:**
```bash
git clone https://github.com/vyfor/cord.nvim ~/.local/share/nvim/site/pack/plugins/start/cord.nvim
```

**Windows (PowerShell):**
```powershell
git clone https://github.com/vyfor/cord.nvim $LOCALAPPDATA/nvim-data/site/pack/plugins/start/cord.nvim
```

> #### ⚙️ Configuring
> ```lua
> require('cord').setup {
>   -- ...
> }
> ```

</details>

<details>
<summary><strong>Considerations</strong></summary>

Cord requires the **server executable** to be present. By default, the plugin automatically fetches it from GitHub, which requires a dependency on [**`curl`**](https://curl.se).

Alternatively, you can provide the executable manually:

- **Download from GitHub:**  
  Get the latest release from [https://github.com/vyfor/cord.nvim/releases/latest](https://github.com/vyfor/cord.nvim/releases/latest), rename it to `cord` (or `cord.exe` on Windows), and place it under `nvim-data-dir/cord/bin`. This is essentially what `:Cord update fetch` does.

- **Build from source:**  
  Run `:Cord update install` to install from crates.io or `:Cord update build` to build from source locally.

</details>

## 🎨 Themes

Cord features over 120 meticulously crafted icons available in distinct themes:

- **Default**: A stylish theme based on [Nerd Fonts](https://github.com/ryanoasis/nerd-fonts) icons.
- **Atom**: A sleek theme based on [Atom Material Icons](https://github.com/AtomMaterialUI/a-file-icon-vscode/).
- **Catppuccin**: A soothing pastel theme based on [Catppuccin](https://github.com/catppuccin/vscode-icons) icons.
- **Minecraft**: A blocky pixel-art set based on [Datapack Icons](https://github.com/FuncFusion/mc-dp-icons).
- **Classic**: A clean theme featuring widely recognized icons.

See the [showcase](https://github.com/vyfor/icons#showcase) for a visual comparison.

> [!TIP]
> Each theme includes multiple flavors, typically `dark`, `light`, and `accent`, representing the background color of the icons.
> Choose your theme in the [`display`](https://github.com/vyfor/cord.nvim/wiki/Configuration#-display) configuration option. More themes are coming soon!

## ❤️ Support the Project
I'm the sole maintainer of cord.nvim and dedicate much of my free time to this project. If you find Cord helpful, you can show your support by giving the repo a star or [sponsoring me on GitHub](https://github.com/sponsors/vyfor). Every bit of support helps me continue to improve and maintain Cord for everyone. Thank you!

<div align="center">  
  <p>💬 Questions? Post in <a href="https://github.com/vyfor/cord.nvim/discussions">Discussions</a> or reach me out on Discord: <a href="https://discord.com/users/446729269872427018"><strong>vyfor</strong></a></p>
  <div><a href="https://discord.gg/q9rC4bjCHv"><img src="https://discord.com/api/guilds/1322899307925602366/widget.png?style=banner3" alt="cord.nvim"/></a></div>
</div>