Commit graph

33 commits

Author SHA1 Message Date
Folke Lemaitre
e039139291
feat(image): configurable templates for math expressions. Closes #1338 2025-02-20 17:11:12 +01:00
Folke Lemaitre
bc902f7032
feat(compat): added svim, a compatibility layer for Neovim. Closes #1321 2025-02-20 06:59:44 +01:00
Folke Lemaitre
97dcd9c168
feat(picker.util): lua globber 2025-02-11 22:22:04 +01:00
Folke Lemaitre
5d42c7e5e4
feat(picker.util): utility function to get all bins on the PATH 2025-02-11 13:41:32 +01:00
Folke Lemaitre
8272c1c66f
fix(all): better support for opening windows / pickers / ... on multiple tab pages. Closes #1043 2025-02-10 11:24:13 +01:00
Folke Lemaitre
5af04ab667
feat(picker): get filetype from modeline when needed. Closes #987 2025-02-07 11:35:16 +01:00
Folke Lemaitre
2528fcb02c
feat(explorer): recursive copy and copying of selected items with c 2025-02-02 20:32:51 +01:00
Folke Lemaitre
5c5b40b5d0
feat(picker.pickwin): optional win/buf filter. Closes #877 2025-02-02 19:35:33 +01:00
Folke Lemaitre
6f8f0d3c72
feat(picker.projects): projects now automatically processes dev folders and added a bunch of actions/keymaps. Closes #871 2025-02-02 16:09:00 +01:00
Folke Lemaitre
6dbc26757c
fix(picker): make pick_win work with split layouts. Closes #834 2025-01-31 19:14:16 +01:00
Folke Lemaitre
5cae48d93c
feat(explorer): added git status. Closes #817 2025-01-31 19:08:32 +01:00
Folke Lemaitre
dad3e00e83
fix(picker.format): extra slash in path 2025-01-31 17:09:08 +01:00
Folke Lemaitre
4e7356c9ad
refactor(picker.actions): move pick_win to util so it can be used outside the picker. Closes #623 2025-01-30 21:04:05 +01:00
Folke Lemaitre
4e30ff0f1e
fix(picker.multi): apply source filter settings for multi source pickers. See #761 2025-01-28 14:19:25 +01:00
Folke Lemaitre
1069d78334
fix(picker.util): proper cwd check for paths. Fixes #754. See #757 2025-01-28 13:21:00 +01:00
Folke Lemaitre
14f16ceb5d
fix(picker.util): prevent empty shortened paths if it's the cwd. Fixes #721 2025-01-23 19:06:55 +01:00
Folke Lemaitre
9d5d3bdb17
feat(picker): added opts.rtp (bool) to find/grep over files in the rtp. See #680 2025-01-23 13:03:27 +01:00
Folke Lemaitre
ee6f21bbd6
fix(picker.util): for -- args require a space before 2025-01-23 12:43:52 +01:00
Folke Lemaitre
bab8243395
feat(picker.util): smart path truncate. Defaults to 40. Closes #708 2025-01-23 12:00:08 +01:00
Folke Lemaitre
97898e910d
feat(picker): added new icons picker for nerd fonts and emoji. Closes #703 2025-01-23 10:51:17 +01:00
Folke Lemaitre
964beb1148
fix(picker.util): more relaxed resolve_loc 2025-01-21 09:23:37 +01:00
Folke Lemaitre
cd5eddb1de
fix(picker): better handling of buffers with custom URIs. Fixes #677 2025-01-21 09:18:33 +01:00
Folke Lemaitre
5e00b0ab27
feat(picker.matcher): new opts.matcher.file_pos which defaults to true to support patterns like file:line:col or file:line. Closes #517. Closes #496. Closes #651 2025-01-20 11:40:06 +01:00
Folke Lemaitre
6b7705c7ed
fix(picker.util): relax pattern for args 2025-01-20 10:37:00 +01:00
Folke Lemaitre
3df2408713
fix(picker.lsp): backward compat with Neovim 0.95 2025-01-20 10:14:28 +01:00
Folke Lemaitre
d0a0046e37
fix(picker.lsp): lazy resolve item lsp locations. Fixes #650 2025-01-20 09:56:12 +01:00
Folke Lemaitre
2ff21b4394
fix(picker.util): item.resolve for nil item 2025-01-20 00:11:36 +01:00
Folke Lemaitre
b0d3266985
feat(picker): added support for item.resolve that gets called if needed during list rendering / preview 2025-01-19 21:53:18 +01:00
Folke Lemaitre
50f3c3e5b1
feat(picker): added support for live args for grep and files. Closes #601 2025-01-19 17:54:25 +01:00
Folke Lemaitre
2e70b7f423
feat(picker): added {preview} and {flags} title placeholders. Closes #557, Closes #540 2025-01-18 09:35:22 +01:00
Folke Lemaitre
7117356b49
perf(picker.util): cache path calculation 2025-01-16 12:57:38 +01:00
Folke Lemaitre
0892db4f42
feat(picker.git): stage/unstage files in git status with <tab> key 2025-01-15 22:12:19 +01:00
Folke Lemaitre
559d6c6bf2
feat(snacks): added snacks.picker (#445)
## Description

More info coming tomorrow.

In short:
- very fast. pretty much realtime filtering/sorting in huge repos (like
1.7 million files)
- extensible
- easy to customize the layout (and lots of presets) with
`snacks.layout`
- simple to create custom pickers
- `vim.ui.select`
- lots of builtin pickers
- uses treesitter highlighting wherever it makes sense
- fast lua fuzzy matcher which supports the [fzf
syntax](https://junegunn.github.io/fzf/search-syntax/) and additionally
supports field filters, like `file:lua$ 'function`

There's no snacks picker command, just use lua.

```lua
-- all pickers
Snacks.picker()

-- run files picker
Snacks.picker.files(opts)
Snacks.picker.pick("files", opts)
Snacks.picker.pick({source = "files", ...})
```

<!-- Describe the big picture of your changes to communicate to the
maintainers
  why we should accept this pull request. -->

## Todo
- [x] issue with preview loc not always correct when scrolling fast in
list (probably due to `snacks.scroll`)
- [x] `grep` (`live_grep`) is sometimes too fast in large repos and can
impact ui rendering. Not very noticeable, but something I want to look
at.
- [x] docs
- [x] treesitter highlights are broken. Messed something up somewhere

## Related Issue(s)

<!--
  If this PR fixes any issues, please link to the issue here.
  - Fixes #<issue_number>
-->

## Screenshots

<!-- Add screenshots of the changes if applicable. -->
2025-01-14 22:53:59 +01:00