diff options
author | Justin Chen <ctj12461@163.com> | 2023-08-13 23:12:59 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-13 11:12:59 -0400 |
commit | 7ab12658f911bebfa12f836b2a6449e08611e437 (patch) | |
tree | c5b00ec5342ff424b05d0f3c1dd283115c73bceb /src/key_command/command.rs | |
parent | 82e231ac004e1f25f0a447bc601e5e3a10dca4d2 (diff) |
feat: Add case sensitivity support for searching, selecting and filtering files (#393)
* feat: Add struct and enum definitons for choosing case sensitivity of search
* feat: Implement `FromStr` for CaseSensitivity
* feat: Add a command to change the configuration of case sensitivity
* feat: Add case sensitivity support for search operations
* feat: Add case sensitivity support for selection operations
* docs: Add explanations for the new feature
* feat: Add case sensitivity support for searching with fzf
* docs: Add explanations for the new feature
* docs: Update documents
* feat: Refactor and add case sensitivity support for the filter operation
* refactor: Extract codes related to constructing the context for searching
* refactor: Extract the common component of searching, selecting and filtering files
* refactor: Change the module path and name
* feat: Use separate options for case sensitivity configurations
* feat: Add support for changing case sensitivity configurations at runtime
* docs: Add explanations for the new command
Diffstat (limited to 'src/key_command/command.rs')
-rw-r--r-- | src/key_command/command.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/key_command/command.rs b/src/key_command/command.rs index 9d20b11..16734f1 100644 --- a/src/key_command/command.rs +++ b/src/key_command/command.rs @@ -1,8 +1,10 @@ use std::path; +use crate::commands::case_sensitivity::SetType; use crate::commands::quit::QuitAction; use crate::config::option::{ - LineMode, LineNumberStyle, NewTabMode, SelectOption, SortType, TabBarDisplayMode, + CaseSensitivity, LineMode, LineNumberStyle, NewTabMode, SelectOption, SortType, + TabBarDisplayMode, }; use crate::io::FileOperationOptions; @@ -112,6 +114,10 @@ pub enum Command { pattern: String, options: SelectOption, }, + SetCaseSensitivity { + case_sensitivity: CaseSensitivity, + set_type: SetType, + }, SetMode, SubProcess { words: Vec<String>, |