<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Mar 4, 2018, at 12:03 PM, William Schmidt via lldb-dev <<a href="mailto:lldb-dev@lists.llvm.org" class="">lldb-dev@lists.llvm.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Hello lldb devs,<br class=""><div class=""><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><div class=""><div class=""><div class=""><br class=""></div>Hacking away at my lldb command history on macOS Darwin 10.13.3<br class=""></div><br class=""></div><div class=""><div style="margin-left:40px" class="">lldb -v =><br class="">lldb-900.0.64<br class=""> Swift-4.0<br class=""></div><div class=""><div class=""><br class="">I
discovered that ESC-b moves the cursor one word to the left, while
ESC-f moves the cursor one word to the right; word in the regular
expression sense. However, lldb does not remember that ESC switches the
mode, as it does in bash. Each movement of the cursor must use that ESC
sequence, such that to move, say 8 words left to get to the beginning of
an 8-word line requires 8 separate ESC-b keyboard events. This is
better than using the left arrow to move one char at a time but lldb
deserves an editing mode functionally equivalent to what bash offers.
And since bash is open-source, it should just be a matter of grabbing
the bash source that implements command line editing and going from
there.<br class=""><br class=""></div><div class="">Am I missing any other ESC sequences that have been implemented but not documented?<br clear="all" class=""></div></div></div></div></div></div></div></div></div></div></blockquote><div><br class=""></div>If you want to see the exact configuration of LLDB's command interpreter see the Editline::ConfigureEditor() function in Editline.cpp. You can edit your ~/.editrc and override anything you want, so it is highly configurable.</div><div><br class=""></div><div>Mine contains:</div><div><br class=""></div><div>$ cat ~/Dropbox/.editrc <br class="">lldb:bind '^[[5C' vi-next-word<br class="">lldb:bind '^[[5D' vi-prev-word<br class="">lldb:bind '^D' ed-delete-next-char<br class="">lldb:bind '^B' ed-command<br class="">lldb:bind '^P' ed-search-prev-history<br class="">lldb:bind '^N' ed-search-next-history</div><div><br class=""></div><div>.editrc is for all apps, but you can bind "lldb" specific bindings as shown above.</div><div><br class=""></div><div>Greg</div><div><br class=""><blockquote type="cite" class=""><div class=""><div dir="ltr" class=""><div class=""><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class="gmail-m_1391238136578316897m_-7363884564374292438gmail_signature"><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><br class="">Regards,<br class=""></div><div class="">Will Schmidt<br class=""><br class=""></div><div class="">T. William Schmidt<br class=""></div><div class="">Ola, AR 72853<br class=""></div><div class=""><a href="mailto:t.william.schmidt@gmail.com" target="_blank" class="">t.william.schmidt@gmail.com</a></div></div></div></div></div></div></div></div></div></div></div></div><br class=""><br class=""><br class=""><br class=""></div></div></div></div></div>
</div>
_______________________________________________<br class="">lldb-dev mailing list<br class=""><a href="mailto:lldb-dev@lists.llvm.org" class="">lldb-dev@lists.llvm.org</a><br class="">http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev<br class=""></div></blockquote></div><br class=""></body></html>