Commit graph

26 commits

Author SHA1 Message Date
Jouni Malinen 4c3b921ebf edit: Add support for prompt string with internal line edit
Signed-hostap: Jouni Malinen <j@w1.fi>
2012-08-05 20:48:25 +03:00
Janusz Dziedzic 2d2398a11f edit: Add support for setting prompt string
Signed-hostap: Janusz Dziedzic <janusz.dziedzic@tieto.com>
2012-08-05 20:46:34 +03:00
Jouni Malinen 0f3d578efc Remove the GPL notification from files contributed by Jouni Malinen
Remove the GPL notification text from the files that were
initially contributed by myself.

Signed-hostap: Jouni Malinen <j@w1.fi>
2012-02-11 19:39:36 +02:00
Jouni Malinen 1e1a0a4dc9 edit: Fix history prev/next selection
Commit 19ec1f262e tried to fix some
cases for history prev selection, but it broke others. Fix this
properly by using a separate entry for the current edit line that
is not yet in history buffer.
2011-10-15 14:03:35 +03:00
Jouni Malinen dfaeda0492 Fix couple of compiler warnings about uninitialized variables 2011-01-26 21:29:28 +02:00
Jouni Malinen e3acc8f1c8 edit: Clear edit line on deinit 2010-11-21 12:07:29 +02:00
Jouni Malinen 566aef60ab edit: Limit maximum number of history entries to 100 2010-11-21 12:04:44 +02:00
Jouni Malinen 70de7d56fe edit: Implement history file read/write 2010-11-21 12:01:50 +02:00
Jouni Malinen 19ec1f262e edit: Fix history prev selection 2010-11-21 11:49:36 +02:00
Jouni Malinen 8953e9681a edit: Move history save file specification to caller 2010-11-21 11:43:09 +02:00
Jouni Malinen ec9aac9468 edit: Use struct dl_list for history buffer 2010-11-21 11:25:34 +02:00
Jouni Malinen 31e1206baa edit: Fix delete_word when not in the end of line 2010-11-20 23:05:12 +02:00
Jouni Malinen 464144a43b edit: Add history buffer search
Ctrl-R can now be used to start history search mode.
2010-11-20 17:55:35 +02:00
Jouni Malinen 42034d6f60 edit: Clean up escape code parser 2010-11-20 16:59:55 +02:00
Jouni Malinen 0bee81352f edit: Split escape code parsing into a separate function
This makes edit_read_char() simpler and easier to extend since it
does not need to know anything about the escape codes anymore.
2010-11-20 15:55:51 +02:00
Jouni Malinen ef6ee3e5a3 edit: Sort completion list 2010-11-20 12:41:15 +02:00
Jouni Malinen 9364990ace edit: Really fix the completion of last character
The previous commit broke completion in various places. The proper
way of handling the completion of full word is to verify whether
there are more than one possible match at that point.
2010-11-20 12:27:06 +02:00
Jouni Malinen 414780027a edit: Fix completion at the last character
Completion needs to be done even if the full word has been entered.
In addition, fix the space-after-full-word to properly allocate room
for the extra character when completion is used in the middle of the
string.
2010-11-20 11:59:04 +02:00
Jouni Malinen 89eb6b774d edit: Fix delete word to update current position 2010-11-20 11:48:00 +02:00
Jouni Malinen e4f13f9256 edit: Fix completion of arguments other than the first one 2010-11-20 11:45:42 +02:00
Jouni Malinen 73669f1b03 edit: Fix Home/End escape codes 2010-11-20 11:20:48 +02:00
Jouni Malinen 7302a35ed4 edit: Add string completion support on tab 2010-11-20 00:42:02 +02:00
Jouni Malinen e8ecb5fb49 Move wpa_cli readline integration into src/utils/edit_readline.c
All three line editing options are now located in src/utils/edit*.c
and provide the same API to allow easy build time selection.
2010-11-14 22:37:43 +02:00
Jouni Malinen bdc45634f0 wpa_cli: Use edit API as a wrapper for optional readline 2010-11-14 21:19:35 +02:00
Jouni Malinen 616e0e728e edit: Redraw input line on ^L 2010-11-14 21:03:24 +02:00
Jouni Malinen 82a855bda8 Move command line editing routines into src/utils/edit*.[ch]
This allows the same routines to be shared with other programs
since these are not really specific to wpa_cli.
2010-11-14 20:59:29 +02:00