Skip to content

Commit ff5d42a

Browse files
AndreasArvidssonpokeypre-commit-ci-lite[bot]
authored andcommitted
Add simple command history analyzer (#2163)
<img width="525" alt="image" src="https://github.com/cursorless-dev/cursorless/assets/755842/fae1bdd3-470a-4c28-b2ef-e47818943b59"> ## Checklist - [ ] I have added [tests](https://www.cursorless.org/docs/contributing/test-case-recorder/) - [ ] I have updated the [docs](https://github.com/cursorless-dev/cursorless/tree/main/docs) and [cheatsheet](https://github.com/cursorless-dev/cursorless/tree/main/cursorless-talon/src/cheatsheet) - [ ] I have not broken the cheatsheet --------- Co-authored-by: Pokey Rule <[email protected]> Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
1 parent b64ab09 commit ff5d42a

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

src/cursorless.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from talon import Module
1+
from talon import Module, actions
22

33
mod = Module()
44

@@ -15,3 +15,9 @@ def private_cursorless_show_settings_in_ide():
1515

1616
def private_cursorless_show_sidebar():
1717
"""Show Cursorless-specific settings in ide"""
18+
19+
def private_cursorless_show_command_statistics():
20+
"""Show Cursorless command statistics"""
21+
actions.user.private_cursorless_run_rpc_command_no_wait(
22+
"cursorless.analyzeCommandHistory"
23+
)

src/cursorless.talon

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,6 @@ tag: user.cursorless
4343

4444
bar {user.cursorless_homophone}:
4545
user.private_cursorless_show_sidebar()
46+
47+
{user.cursorless_homophone} stats:
48+
user.private_cursorless_show_command_statistics()

0 commit comments

Comments
 (0)