Skip to content

Commit ebd949b

Browse files
committed
docs(readme): polish
1 parent 1f8a534 commit ebd949b

File tree

1 file changed

+15
-44
lines changed

1 file changed

+15
-44
lines changed

README.md

Lines changed: 15 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ This section should guide you to run your first builtin pickers.
4444

4545
[Neovim (>v0.10.4)](https://github.com/neovim/neovim/releases/tag/v0.10.4) or the
4646
latest neovim nightly commit is required for `telescope.nvim` to work.
47-
The neovim version also needs to be compiled with LuaJIT, we currently do not
48-
support Lua5.1 because of some ongoing issues.
47+
The neovim version also needs to be compiled with LuaJIT; PUC Lua is not fully supported,
48+
both for performance reasons and because extensions may rely on FFI.
4949

5050
### Required dependencies
5151

@@ -56,40 +56,35 @@ support Lua5.1 because of some ongoing issues.
5656
- [BurntSushi/ripgrep](https://github.com/BurntSushi/ripgrep) is required for
5757
`live_grep` and `grep_string` and is the first priority for `find_files`.
5858

59-
We also suggest you install one native telescope sorter to significantly improve
60-
sorting performance. Take a look at either
61-
[telescope-fzf-native.nvim](https://github.com/nvim-telescope/telescope-fzf-native.nvim)
59+
We also strongly suggest installing a native telescope sorter to significantly improve
60+
sorting performance:
61+
* [telescope-fzf-native.nvim](https://github.com/nvim-telescope/telescope-fzf-native.nvim)
6262
or
63-
[telescope-fzy-native.nvim](https://github.com/nvim-telescope/telescope-fzy-native.nvim).
63+
* [telescope-fzy-native.nvim](https://github.com/nvim-telescope/telescope-fzy-native.nvim).
6464
For more information and a performance benchmark take a look at the
6565
[Extensions](https://github.com/nvim-telescope/telescope.nvim/wiki/Extensions)
6666
wiki.
6767

6868
### Optional dependencies
6969

7070
- [sharkdp/fd](https://github.com/sharkdp/fd) (finder)
71-
- [neovim LSP](https://neovim.io/doc/user/lsp.html) (picker)
7271
- [devicons](https://github.com/nvim-tree/nvim-web-devicons) (icons)
7372

7473
### Installation
7574

7675
It is suggested to either use the latest release
77-
[tag](https://github.com/nvim-telescope/telescope.nvim/tags) or our release
78-
branch (which will get consistent updates)
79-
[0.1.x](https://github.com/nvim-telescope/telescope.nvim/tree/0.1.x).
80-
81-
It is not suggested to run latest master.
76+
[tag](https://github.com/nvim-telescope/telescope.nvim/tags).
8277

8378
Using [vim-plug](https://github.com/junegunn/vim-plug)
8479

85-
```viml
80+
```vim
8681
Plug 'nvim-lua/plenary.nvim'
8782
Plug 'nvim-telescope/telescope.nvim', { 'tag': 'v0.1.9' }
8883
```
8984

9085
Using [dein](https://github.com/Shougo/dein.vim)
9186

92-
```viml
87+
```vim
9388
call dein#add('nvim-lua/plenary.nvim')
9489
call dein#add('nvim-telescope/telescope.nvim', { 'rev': 'v0.1.9' })
9590
```
@@ -110,7 +105,7 @@ return {
110105
}
111106
```
112107

113-
### checkhealth
108+
### Checkhealth
114109

115110
Make sure you call `:checkhealth telescope` after installing telescope to ensure
116111
everything is set up correctly.
@@ -123,24 +118,6 @@ to get an understanding of how to use Telescope and how to configure it.
123118
Try the command `:Telescope find_files`
124119
to see if `telescope.nvim` is installed correctly.
125120

126-
Using VimL:
127-
128-
```viml
129-
" Find files using Telescope command-line sugar.
130-
nnoremap <leader>ff <cmd>Telescope find_files<cr>
131-
nnoremap <leader>fg <cmd>Telescope live_grep<cr>
132-
nnoremap <leader>fb <cmd>Telescope buffers<cr>
133-
nnoremap <leader>fh <cmd>Telescope help_tags<cr>
134-
135-
" Using Lua functions
136-
nnoremap <leader>ff <cmd>lua require('telescope.builtin').find_files()<cr>
137-
nnoremap <leader>fg <cmd>lua require('telescope.builtin').live_grep()<cr>
138-
nnoremap <leader>fb <cmd>lua require('telescope.builtin').buffers()<cr>
139-
nnoremap <leader>fh <cmd>lua require('telescope.builtin').help_tags()<cr>
140-
```
141-
142-
Using Lua:
143-
144121
```lua
145122
local builtin = require('telescope.builtin')
146123
vim.keymap.set('n', '<leader>ff', builtin.find_files, { desc = 'Telescope find files' })
@@ -284,12 +261,6 @@ explained in `:help telescope.defaults.mappings`.
284261

285262
Built-in functions. Ready to be bound to any key you like.
286263

287-
```vim
288-
:lua require'telescope.builtin'.planets{}
289-
290-
:nnoremap <Leader>pp :lua require'telescope.builtin'.planets{}
291-
```
292-
293264
### File Pickers
294265

295266
| Functions | Description |
@@ -452,8 +423,8 @@ For more details on resolving sizes, see `:help telescope.resolve`.
452423
As an example, if we wanted to specify the layout strategy and width,
453424
but only for this instance, we could do something like:
454425

455-
```
456-
:lua require('telescope.builtin').find_files({layout_strategy='vertical',layout_config={width=0.5}})
426+
```lua
427+
require('telescope.builtin').find_files({layout_strategy='vertical',layout_config={width=0.5}})
457428
```
458429

459430
If we wanted to change the width for every time we use the `vertical`
@@ -525,7 +496,7 @@ a theme, check out `lua/telescope/themes.lua`.
525496
All `telescope.nvim` functions are wrapped in `vim` commands for easy access,
526497
tab completions and setting options.
527498

528-
```viml
499+
```vim
529500
" Show all builtin pickers
530501
:Telescope
531502
@@ -588,9 +559,9 @@ tab completions will not be available right away.
588559
Pickers from extensions are added to the `:Telescope` command under their
589560
respective name. For example:
590561

591-
```viml
562+
```vim
592563
" Run the `configurations` picker from nvim-dap
593-
:Telescope dap configurations
564+
Telescope dap configurations
594565
```
595566

596567
They can also be called directly from Lua:

0 commit comments

Comments
 (0)