summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCanop <cano.petrole@gmail.com>2020-01-09 18:12:09 +0100
committerCanop <cano.petrole@gmail.com>2020-01-09 18:12:09 +0100
commita0477be58aecb84335becf5424802718bf8fbdbf (patch)
tree51cf4b0f7c1aa23e4cc3dc55ea24c57166f6f441
parentba5f2b8560e744262dff92fe5c297c1ed6e93eef (diff)
ctrl-c is another way to quit brootv0.11.4
This is defined by configuration, so users having already configured broot won't be affected unless they add this to their conf.toml file: [[verbs]] key = "ctrl-c" execution = ":quit" Fix #97
-rw-r--r--CHANGELOG.md1
-rw-r--r--README.md2
-rw-r--r--src/conf.rs4
3 files changed, 6 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 51a2556..7a2353e 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -3,6 +3,7 @@
- make :open_stay and :open_leave work in help screen (applying on configuration file)
- Mac/fish: use ~/.config/fish even on systems where the config home is usually different
- Mac/bash: add .bash_profile to the list of possible sourcing files
+- define ctrl-c as a new way to quit
<a name="v0.11.3"></a>
### v0.11.3 - 2020-01-09
diff --git a/README.md b/README.md
index 02d7fa4..c3dcf5e 100644
--- a/README.md
+++ b/README.md
@@ -42,7 +42,7 @@ Most useful keys for this:
* `<enter>` to select a directory (staying in broot)
* `<esc>` to get back to the previous state or clear your search
* `<alt><enter>` to get back to the shell having `cd` to the selected directory
-* `:q` if you just want to quit (`<esc>` works too)
+* `:q` if you just want to quit (`<esc>`, or `<ctrl><q>` or `<ctrl><c>` work too)
### Never lose track of file hierarchy while you search
diff --git a/src/conf.rs b/src/conf.rs
index cad675c..530a055 100644
--- a/src/conf.rs
+++ b/src/conf.rs
@@ -185,6 +185,10 @@ shortcut = "e"
execution = "$EDITOR {file}"
[[verbs]]
+key = "ctrl-c"
+execution = ":quit"
+
+[[verbs]]
invocation = "create {subpath}"
execution = "$EDITOR {directory}/{subpath}"