Commit Graph

43 Commits

Author SHA1 Message Date
Gregory Anders
7df6662394 fix: also map <C-/> for which-key (#2051)
Some terminals send Ctrl + / as <C-/>, not <C-_>. Map both to the
which_key action to cover these cases.
2022-07-07 22:19:35 +02:00
Simon Hauser
f838695459 chore: reformat with stylua 0.14.0 2022-07-07 08:27:46 +02:00
Dave Lage
697ee7aa70 feat: lua autocmd (#1707) 2022-04-22 16:20:59 +02:00
Waldson Patrício
1a72a92b64 feat: enable individual options for mappings (#890)
Co-authored-by: Simon Hauser <Simon-Hauser@outlook.de>
2022-03-20 21:34:07 +01:00
Simon Hauser
9f0dd2e402 fix: action mt again (#1487)
actions should be concatinable again
2022-03-13 19:22:16 +01:00
Dave G
749ce3b8ca feat: Add <C-w> to default mappings (#1650)
As described in https://github.com/nvim-telescope/telescope.nvim/issues/1579, this adds <C-w> to the default mappings.
2022-01-05 23:36:41 +01:00
Simon Hauser
1c57cc6140 Revert "fix: action mt so we can again concat actions from two different tables (#1143)" (#1486)
This reverts commit 6daf35c88c.
2021-11-23 23:51:25 +01:00
Simon Hauser
6daf35c88c fix: action mt so we can again concat actions from two different tables (#1143)
* fix: action mt so we can again concat actions from two different tables

- without actually changing the public interface
- without having a local table that keeps track of all actions

* this should clear actions now

we never actually called this function which is kinda a problem because
we never cleaned up previous mapping stores.
We can also make a better mappings store which has access to the keys
sequences which would help the showing actions part

* bugfix

* that should now clear everything

only tests left i think

* more tests

* cleanup

* hack: make sure all actions get cleared
2021-11-22 20:48:37 +01:00
Luke Kershaw
bf77c5d2fa feat: results scrolling actions (#1436) 2021-11-13 11:15:07 +00:00
Zachary Churchill
3f45d64e9c feat: add gg and G to default mappings (#1325)
* feat: add `gg` and `G` to default mappings

* refactor: use action_state.get_current_picker

* docs: mention new default gg/G keymaps
2021-10-11 18:14:23 +02:00
fdschmidt93
fbe004142f feat: show keymaps for builtin actions (#1084)
* Add default mappings `<C-/>`and `?` for insert and normal mode, respectively, to show registered keymappings (`actions.which_key`) attached to prompt buffer
2021-09-01 20:11:53 +02:00
Joshua Cao
b47bb8df1e mapping: Remove center action after select_default action in default mappings. (#974) 2021-08-20 12:02:22 -04:00
Simon Hauser
79644ab677 chore: use stylua for formatting (#1040)
* chore: stylua job and config

* reformat with stylua
2021-07-23 11:42:37 -04:00
Simon Hauser
618e0e6075 feat: set defaults for each picker in telescope setup (#883)
This allows easier picker configuration for example:

```lua
require("telescope").setup {
  pickers = {
    buffers = {
      show_all_buffers = true,
      sort_lastused = true,
      theme = "dropdown",
      previewer = false,
      mappings = {
        i = {
          ["<c-q>"] = "smart_send_to_qflist",
        }
      }
    }
  }
}
```

This configuration will be applied when running `:Telescope buffers`
2021-06-09 19:51:03 +02:00
fdschmidt93
559bf36e73 feat: add completion to pre-filtering (#626)
Works by pressing `<C-l>` in insert mode. Supported are all builtins that have prefiltering. Means:
- lsp_workspace_symbols
- lsp_workspace_diagnostics
- lsp_document_symbols
- lsp_document_diagnostics
2021-03-09 21:04:21 +01:00
TJ DeVries
390e5fa9f5 fix: Keep remaps safe between reloads 2021-03-03 13:26:57 -05:00
Volodymyr Kot
ee341b02ea feat: add ability to multiselect in reverse direction (#573)
Use Shift+Tab
2021-02-28 10:18:11 +01:00
TJ DeVries
11674ac021 feat: multi selection. Only integrates with send_selected_to_qflist (#551)
This will not yet work with select actions. More work is needed in that case.

Co-authored-by: Simon Hauser <Simon-Hauser@outlook.de>
2021-02-27 21:06:04 +01:00
Hubert Pelczarski
67b0661537 feat: adds M mapping in normal mode (#544) 2021-02-24 03:35:52 +01:00
Simon Hauser
10627e889e feat: advanced normal mode (#463)
Add <count>j and k to normal mode and H and L to jump at top and bottom of displayed results
2021-02-24 02:41:00 +01:00
TJ DeVries
d7c02e3b52 feat: Action improvements (#472)
* feat: replace_map

* feat: Add action_set and action_state

* fix: Move all actions.get_ to action_state.get_

* fix: replace all internal references of _goto_file_selection_edit

* feat: add some docs

* fix: lint

* feat: actions.select

* remove mentions and usage of goto_file_selection APIs

* feat: special case attach_mappings to be overridable and defaultable

* Having goto_file_selection mappings will cause a error

as well as replacing deprecated goto_file_selection methodes

For config and replacing use this instead:
- actions.select_default
- actions.select_horizonal
- actions.select_vertical
- actions.select_tab

Only replacing:
- actions.set.edit -- for replacing all select functions

* adds actions.state.select_key_to_edit_key

Co-authored-by: Simon Hauser <Simon-Hauser@outlook.de>
2021-02-22 11:30:57 -05:00
anott03
5995a8be8f Undo #465 (#469)
We have broke all extension that do some sort of goto_file_selection:replace

Problem described here: https://github.com/nvim-telescope/telescope.nvim/pull/465#issuecomment-767831897
Possible solution: https://github.com/nvim-telescope/telescope.nvim/pull/465#issuecomment-767808213
2021-01-27 17:22:11 +01:00
anott03
ccbb7f5638 fix: move to actions.select as default action (#465) 2021-01-25 19:20:01 +01:00
Julian Berman
0f9fd84a97 fix: Use noremap when mapping. (#286)
Previously, if e.g. : was remapped, Telescope would be unclosable with
its mappings (<Esc>).

(Do the same for ensuring we :silent)
2020-11-24 15:29:46 -05:00
Simon Hauser
aba433c522 feat: Actions can now be summed up and center action (#204)
Closes: #182 

* Actions can now be summed up and center action

* fix: Make some complicated changes for metatable

* Update documentation

Co-authored-by: TJ DeVries <devries.timothyj@gmail.com>
2020-11-02 17:00:23 -05:00
TJ DeVries
282e328d46 fix: Allow people to still override ALL the mappings 2020-10-08 21:42:50 -04:00
TJ DeVries
c2c4626c3d feat: Add more easily customizable mappings.
Closes: #131
2020-10-08 21:39:43 -04:00
runiq
675e240383 Normalize mappings (#28)
Modes now use lowercase keys, mappings use the internal representation
via `nvim_replace_termcodes()`.
2020-09-06 22:51:36 -04:00
runiq
f5f1275411 Fix mapping prefix (#26)
`<cmd>` doesn't trigger `InsertLeave`.
2020-09-04 14:27:39 -04:00
TJ DeVries
a6c883ce36 breaking: change attach_mappings to take bufnr as first argument 2020-09-04 11:01:10 -04:00
TJ DeVries
061307233c feat: add some new items and make mappings easier 2020-09-02 00:06:07 -04:00
TJ DeVries
6b066cf9e8 feat: Add better mapping support 2020-08-31 00:06:53 -04:00
TJ DeVries
a6fe9721ac wip: start on mappings 2020-08-31 00:06:53 -04:00
TJ DeVries
7c921b288f feat: Add escape spamming 2020-08-29 23:18:01 -04:00
TJ DeVries
1c2b1e0d0d Try to fix thing for rocker 2020-08-29 22:22:51 -04:00
TJ DeVries
ae9b769299 feat: Add selection and start actions 2020-08-29 22:15:40 -04:00
TJ DeVries
9bd53098f8 fix: Hopefully fix opening preview window sometime 2020-08-28 15:32:42 -04:00
TJ DeVries
f2fcdcb675 feat: borders and no previews for rocker 2020-08-28 00:19:10 -04:00
TJ DeVries
4100795d0c slightly better small screen UX 2020-08-27 22:55:44 -04:00
TJ DeVries
7e9f38a87e feat: Add livegrep and lsp referecnes 2020-08-27 22:12:47 -04:00
TJ DeVries
fa0382d93e Streamed some refactoring. More work to do 2020-07-31 00:05:22 -04:00
TJ DeVries
ababfbfd88 Another stream 2020-07-17 00:03:20 -04:00
TJ DeVries
c6f0142fc6 Get simple rg example to work 2020-07-15 17:53:30 -04:00