https://github.com/giannibyoung/chezmoi-telescope.nvim
Custom Telescope Picker for Chez Moi Managed Dot files
https://github.com/giannibyoung/chezmoi-telescope.nvim
neovim-plugin neovim-plugin-lua neovim-plugins
Last synced: about 1 year ago
JSON representation
Custom Telescope Picker for Chez Moi Managed Dot files
- Host: GitHub
- URL: https://github.com/giannibyoung/chezmoi-telescope.nvim
- Owner: GianniBYoung
- License: gpl-3.0
- Created: 2024-05-29T01:20:33.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2025-01-05T23:04:42.000Z (over 1 year ago)
- Last Synced: 2025-04-05T05:12:52.698Z (about 1 year ago)
- Topics: neovim-plugin, neovim-plugin-lua, neovim-plugins
- Language: Lua
- Homepage:
- Size: 37.1 KB
- Stars: 23
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# chezmoi-telescope.nvim
Custom Telescope Picker for Chez Moi Managed Dot Files!
Also adds neovim commands to:
- `add`
- `forget`
- 're-add'
- Chezmoi does not overwrite template files and neither will this command
- `update` chezmoi's source
# Installation
All that is needed is to install the plugin and load the `telescope extension` via `require("telescope").load_extension("chezmoi")`.
Here is an example with Lazy:
```lua
{
"nvim-telescope/telescope.nvim",
dependencies = {
{ "GianniBYoung/chezmoi-telescope.nvim" },
},
config = function()
require("telescope").load_extension("chezmoi")
end,
}
```
## Pre-reqs
- [Chez Moi](https://www.chezmoi.io/)
- [Telescope](https://github.com/nvim-telescope/telescope.nvim/tree/master)
- [nvim-web-devicons (optional)](https://github.com/nvim-tree/nvim-web-devicons)
## Usage
- `:Telescope chezmoi dotfiles` -> Open telescope picker populated with Chezmoi managed dot files
- This opens the file in chezmoi's source dir
- `:Telescope chezmoi dotfiles liveDots=true` -> Open telescope picker populated with (Live) Chezmoi managed dot files
- This opens the actual dotfile on your system
- `:ChezmoiAdd` -> `add` the current file to Chezmoi
- `:ChezmoiReAdd` -> `re-add` the current file to Chezmoi
- `:ChezmoiRemove` -> `remove` the current file from Chezmoi
- `:ChezmoiUpdate` -> Pull down the remote source
### Options
The available options are:
- `icons` bool(true) - Enable or disable icons
- `liveDots` bool(false) - Populate the picker with the actual dotfiles your system is using - aka 'live dot files'
Options can be set in the following ways:
1. `:Telescope chezmoi dotfiles option1=value1 option2=bool2`
2. `require('telescope').extensions.chezmoi.dotfiles({option1="value1", option2=bool2})`
# Features
This plugin provides a custom picker for telescope that populates results with files from `$CHEZMOI_SOURCE_DIR` and opens the result in a new buffer on selection.
# Roadmap
- Better icons in picker
- Better error handling
# Contributing
If this plugin is missing functionality for your use case please open an issue or submit a PR!