Skip to content

Commit

Permalink
doc: Rephrase the doc for navigation keymap
Browse files Browse the repository at this point in the history
  • Loading branch information
limoiie committed Jan 20, 2021
1 parent 8c3a0f0 commit e9e085a
Showing 1 changed file with 18 additions and 9 deletions.
27 changes: 18 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,11 @@ LeetCode brings you offer, and now Emacs brings you LeetCode!

1. Execute `leetcode` command, and in problem list buffer:

| keymap | command |
| Keymap | Description |
|--------|----------------------------------------|
| n | cursor move down |
| p | cursor move up |
| l | change prefer language |
| o | show current problem |
| O | show problem by id |
| v | view current problem |
| V | view problem by id |
| b | show current problem in browser |
| B | show problem by id in browser |
| c | solve current problem |
| C | solve problem by id |
| s | filter problems by regex |
| t | filter problems by tag |
| d | filter problems by difficulty |
Expand All @@ -31,6 +23,8 @@ LeetCode brings you offer, and now Emacs brings you LeetCode!
| RET | show current problem description |
| TAB | view current problem description |

More advanced navigation hotkeys can be found [here](#advanced-navigation).

2. Press `<RET>`, show problem description, move cursor to "solve it", press
`<RET>` again, start coding!

Expand All @@ -39,6 +33,21 @@ LeetCode brings you offer, and now Emacs brings you LeetCode!

![leetcode-submit](images/leetcode-submit.png)

## Advanced Navigation

Here are some advanced navigation hotkeys that may be useful in problem list buffer:

| Keymap | Command | Description |
|--------|--------------------------------------------|-------------------------------------|
| o | `leetcode-show-problem` | show/open the current problem |
| O | `leetcode-show-current-problem` | show/open a problem by id |
| v | `leetcode-view-problem` | view the current problem |
| V | `leetcode-view-current-problem` | view a problem by id |
| b | `leetcode-show-problem-in-browser` | show the current problem in browser |
| B | `leetcode-show-current-problem-in-browser` | show a problem by id in browser |
| c | `leetcode-solve-problem` | start coding the current problem |
| C | `leetcode-solve-current-problem` | start coding a problem by id |

# Installation

- Vanilla Emacs: `package-install` it from melpa directly
Expand Down

0 comments on commit e9e085a

Please sign in to comment.