1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-02-03 03:00:04 +08:00
SpaceVim/docs/layers/foldsearch.md

39 lines
936 B
Markdown
Raw Normal View History

2020-04-26 18:49:22 +08:00
---
title: "SpaceVim foldsearch layer"
description: "This layer provides functions that fold away lines that don't match a specific search pattern."
---
# [Available Layers](../) >> foldsearch
<!-- vim-markdown-toc GFM -->
2020-04-27 23:28:19 +08:00
- [Intro](#intro)
- [Install](#install)
2020-04-26 18:49:22 +08:00
- [Key bindings](#key-bindings)
<!-- vim-markdown-toc -->
2020-04-27 23:28:19 +08:00
## Intro
2020-04-26 18:49:22 +08:00
This layer provides functions that fold away lines that don't match a specific search pattern.
2020-04-27 23:28:19 +08:00
The search pattern can be a word or a regular expression.
## Install
To use this layer, add it to your configuration file.
2020-04-26 18:49:22 +08:00
```toml
[layers]
name = "foldsearch"
```
2020-04-27 23:28:19 +08:00
This layer requires [ripgrep](https://github.com/BurntSushi/ripgrep).
2020-04-26 18:49:22 +08:00
## Key bindings
2020-04-27 23:28:19 +08:00
| Key bindings | Description |
| ------------ | ----------------------------- |
| `SPC F w` | foldsearch input word |
| `SPC F W` | foldsearch cursor word |
| `SPC F e` | foldsearch regular expression |