ENB: c.interactive and the new summary command

28 views
Skip to first unread message

Edward K. Ream

unread,
Nov 18, 2023, 8:52:35 AM11/18/23
to leo-editor

This Engineering Notebook post reminds Leonistas that you can easily create interactive commands using the c.interactive helpers. CheatSheet.leo mentions these helpers, but a more detailed discussion is timely.


#3649 suggests creating an interactive summary command. The command prompts the user for a regex and returns a sorted list of all unique matches. I discovered the need for this command while studying the code for Ruff Format.


The first comment of #3649 contains prototype code for the summarize command. The script prompts the user for a regular expression and then creates a top-level node containing the summary.


Summary


The summary command is more concise than the find-all and cff commands. I use summaries to suggest further cffs.


Leonistas can easily create similar commands using c.interactive1, c.interactive2, and c.interactive3.


Edward

Reply all
Reply to author
Forward
0 new messages