aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkoekeishiya <aasvi93@hotmail.com>2018-05-10 16:00:06 +0200
committerkoekeishiya <aasvi93@hotmail.com>2018-05-10 16:00:06 +0200
commit73abf77e71c75aaea8ee181da26b7994ba69de6f (patch)
tree5354fe7332f8a26f91cc4c7a96f8b927a6ae1a97
parent4008137b6d7fce71271c8121b58a3f1ebdc0c430 (diff)
downloadskhd-73abf77e71c75aaea8ee181da26b7994ba69de6f.tar.gz
skhd-73abf77e71c75aaea8ee181da26b7994ba69de6f.zip
update readme
-rw-r--r--README.md40
1 files changed, 14 insertions, 26 deletions
diff --git a/README.md b/README.md
index 9b8cc59..b0ec20a 100644
--- a/README.md
+++ b/README.md
@@ -4,25 +4,17 @@
(although rewritten from scratch), that sacrifices the more advanced features in favour of increased responsiveness and performance.
**skhd** is able to hotload its config file, meaning that hotkeys can be edited and updated live while **skhd** is running.
-**skhd** has an improved parser that is able to accurately identify both the line and character position of any symbol that does not
-follow the correct grammar rules for defining a hotkey. If a syntax error is detected during parsing, the parser will print the error and abort.
-**skhd** will still continue to run and when the syntax error has been fixed, it will automatically reload and reparse the config file.
-
feature comparison between **skhd** and **khd**
| feature | skhd | khd |
|:--------------------------:|:----:|:---:|
| hotload config file | [x] | [ ] |
-| store hotkeys in hashmap | [x] | [ ] |
-| require unix domain socket | [ ] | [x] |
| hotkey passthrough | [x] | [x] |
| modal hotkey-system | [x] | [x] |
| application specific hotkey| [ ] | [x] |
| modifier only hotkey | [ ] | [x] |
| caps-lock as hotkey | [ ] | [x] |
| mouse-buttons as hotkey | [ ] | [x] |
-| emit keypress | [ ] | [x] |
-| autowrite text | [ ] | [x] |
### Install
@@ -58,7 +50,6 @@ Requires xcode-8 command-line tools.
-c | --config: Specify location of config file
skhd -c ~/.skhdrc
-
```
### Configuration
@@ -102,27 +93,24 @@ command = command is executed through '$SHELL -c' and
an EOL character signifies the end of the bind.
```
-A mode can be defined in two different ways:
+A mode is declared according to the following rules:
```
-# define mode 'switcher' with an on_enter command
-:: switcher : chunkc border::color 0xff24ccaa
-# define modes without an on_enter command
-:: swap
-:: focus
-```
+mode_decl = '::' <name> '@' ':' <command> | '::' <name> ':' <command> |
+ '::' <name> '@' | '::' <name>
-Modal sample:
-```
-# defines a new mode named 'test'
-:: test
+name = desired name for this mode,
-# from 'default' mode, activate mode 'test'
-cmd - x ; test
+@ = capture keypresses regardless of being bound to an action
-# from 'test' mode, activate mode 'default'
-test < cmd - x ; default
+command = command is executed through '$SHELL -c' and
+ follows valid shell syntax. if the $SHELL environment
+ variable is not set, it will default to '/bin/bash'.
+ when bash is used, the ';' delimeter can be specified
+ to chain commands.
+
+ to allow a command to extend into multiple lines,
+ prepend '\' at the end of the previous line.
-# launch a new terminal instance when in either 'default' or 'test' mode
-default, test < cmd - return : open -na /Applications/Terminal.app
+ an EOL character signifies the end of the bind.
```