Commit Graph

168 Commits

Author SHA1 Message Date
Joachim Nilsson
7a9e467251 Don't force automake v1.11, require at least v1.11
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-25 15:10:46 +02:00
Joachim Nilsson
6ad3cc1df5 Bump version and update ChangeLog for v1.15.0 release.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 13:26:03 +02:00
Joachim Nilsson
7abfadd7e6 Attempt to work around slightly bogus Coverity warnings.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 13:06:39 +02:00
Joachim Nilsson
9fbad9dbff Fix build problems after removal of generated files.
Restore custom INSTALL file, accidentally removed in 295f901.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 12:44:19 +02:00
Joachim Nilsson
474b9a6548 Instruct Travis-CI to run autogen.sh before configure
After removal of autoconf & automake generated friends we must run
./autogen.sh before configre.

Also, use docker to speed up builds (we don't need root).

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 12:00:02 +02:00
Joachim Nilsson
9865d7fe9f Update ChangeLog and fix Markdown syntax for links.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 11:18:00 +02:00
Joachim Nilsson
e35b8f2fd0 Rename CHANGELOG.md --> ChangeLog.md
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 11:09:37 +02:00
Joachim Nilsson
c10241745c Fix invalid Markdown syntax in README, and minor improvements.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 11:07:14 +02:00
Joachim Nilsson
295f901800 Remove generated files from autoconf et al, run ./autogen.sh instead.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-10 10:58:09 +02:00
C0deH4cker
a1ca0d46ac Include <sys/ioctl.h> before calling ioctl() for Clang on OX X
At least when building with Clang on OS X, there is an error on
[line 1120 of editline.c][err] caused by using the `ioctl()` function
without first declaring it by including its header `<sys/ioctl.h>`.
Adding this line makes the build complete without error.

[err]: https://github.com/troglobit/editline/blob/master/src/editline.c#L1120

Signed-off-by: C0deH4cker <c0deh4cker@gmail.com>
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-09-08 08:23:59 +02:00
Joachim Nilsson
256e288331 Update CHANGELOG and README slightly, bump version to 1.15.0-rc1
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-04-06 15:24:34 +02:00
Joachim Nilsson
9c163ff72b Rename define CONFIG_ANNOYING_NOISE --> CONFIG_TERMINAL_BELL
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-04-06 15:24:28 +02:00
Joachim Nilsson
6a8556733a Add support for disabling default SIGINT and EOF behavior.
This patch adds support for `--disable-eof` and `--disable-sigint` to
the Editline configure script.  With either of these two switches the
`tty_special()` function bypasses the special TTY checks making it
possible to bind Ctrl-C and Ctrl-D to custom callbacks.  This can be
useful if you want to emulate a Cisco style CLI rather than traditional
UNIX.

The user can of course also redefine the VINTR and VEOF special terminal
control characters, but these configure script switches may be easier to
use for some.

Also, the CLI example has been updated to bind Ctrl-D, Ctrl-C and Ctrl-Z
for testing purposes.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-04-06 14:53:47 +02:00
Toby Goodwin
a2bc89db64 Allow Ctrl-D to return EOF
This commit reverts parts of 111fc5e, which originally was intended to
add support for custom key bindings at pos 0, or more specifically, to
be able to change the behavior of Ctrl-D.  However this completely broke
compatibility with the original EOF behavior.

Signed-off-by: Toby Goodwin <toby@paccrat.org>
Signed-off-by: Joachim Nilsson <joachim.nilsson@westermo.se>
2015-04-06 14:46:57 +02:00
Joachim Nilsson
256e6106c7 Minor touch-up.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-03 21:34:15 +01:00
Joachim Nilsson
426a32f771 Convert TODO to Markdown format.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-03 21:32:26 +01:00
Joachim Nilsson
33ff6d5e0e Rename TODO --> TODO.md and add compat symlink.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-03 21:25:31 +01:00
Joachim Nilsson
473602aa08 README.md: Fix missing links and add Build section.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-01 15:28:20 +01:00
Joachim Nilsson
bb9e5e176f CHANGELOG.md: Massive update after audit.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-01 15:14:44 +01:00
Joachim Nilsson
c497555bec editline.c:find_key_in_map() -- Add check to prevent out of bounds access.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-01 15:03:19 +01:00
Joachim Nilsson
528581cb48 README.md: Add API and Example sections, and refactor section slightly.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-01 14:59:24 +01:00
Joachim Nilsson
e4b1078234 editline.3: Update man page slightly and fix example formatting.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-02-01 14:58:17 +01:00
Joachim Nilsson
b00453554f Update to keepachangelog.com format and add to install+dist
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-01-28 23:33:50 +01:00
Joachim Nilsson
98583f8d0f Rename NEWS --> CHANGELOG
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-01-28 23:14:53 +01:00
Joachim Nilsson
01537e3bc0 Cleanup and improve Markdown syntax, inspired by libuEv
Still need to add an API overview and a useful but still simple example.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2015-01-28 23:13:20 +01:00
Joachim Nilsson
8fbc87707e Fix out-of-bounds access in user key binding routines.
Coverity CID #56737, #56738

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-11-04 23:50:48 +01:00
Joachim Nilsson
394c4f82a9 Fix suspicious use of sizeof(char **), same as sizeof(char *) but not portable.
Coverity CID #56740, #56741, #56742

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-11-04 23:42:39 +01:00
Joachim Nilsson
e53ccf61f2 Refactor: replace variables named 'new' with non-reserved word.
The word 'new' is a reserved keyword in C++ and C#, replacing it
with something else is one step further to making it possible to
build editline with a C++ compiler.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-11-04 23:19:48 +01:00
Joachim Nilsson
cd50714e29 Fix memory leak in completion handler.
Coverty CID #56739

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-11-04 23:03:32 +01:00
Mattias Walström
7cd7fc4b61 Add support for el_no_hist to disable access to and auto-save of history.
This commit adds a new global variable 'el_no_hist' which can be used
to disable auto-save of history as well as access to history using prev
and next keybindings (up/down arrows).

Signed-off-by: Mattias Walström <lazzer@gmail.com>
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-11-04 22:47:55 +01:00
Joachim Nilsson
f7432fbfbd Add missing security token to Coverity Scan.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-17 05:57:41 +02:00
Joachim Nilsson
9fd8e0b4d3 Add support for Coverity Scan of editline and add neat gfx to README
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-17 05:56:10 +02:00
Joachim Nilsson
26bc0716b7 Travis CI integration
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-17 05:51:45 +02:00
Joachim Nilsson
bd9c8ddda6 Add some GNU readline compat functions for prompt handling and redisplay
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-17 05:49:06 +02:00
Joachim Nilsson
85e606d093 Bump version for release, v1.14.2
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-14 04:27:38 +02:00
Joachim Nilsson
9cc0cc1ccd Create Markdown versions of README and NEWS and update for release
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-14 04:24:18 +02:00
Joachim Nilsson
08b7f57c98 src/sysunix.c: Restart syscalls on spurious EINTR
Handle tcgetattr(), tcsetattr() and ioctl() by wrapping them in
a retry-loop and restarting them when receiving EINTR.

Should fix problem with sporadic error messages on the console
like this one:

     'Failed tcsetattr: Interrupted system call'

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-09-14 03:44:24 +02:00
Joachim Nilsson
29b7f91165 Fix el_no_echo bug leaking secrets to screen and history
This patch makes el_no_echo actually work:

- Don't echo to screen
- Don't save to history

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2014-06-25 03:06:07 +02:00
Joachim Nilsson
7330f21c28 Bump version for release
o Bump minor version for release
o Update maintainer email address
o Change to tar.xz for archive distribution

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2013-07-08 21:23:16 +02:00
Joachim Nilsson
33ffb150f2 Cleanup configure.ac and regenerate default configure files. 2013-07-08 16:47:03 +02:00
Joachim Nilsson
4bc12834fe Only clear ScreenCount if write() succeeded. 2013-07-08 16:34:32 +02:00
Joachim Nilsson
c7a6ff9317 Return el_status_t from el_bind_key() and el_bind_key_in_metamap()
The two functions el_bind_key() and el_bind_key_in_metamap() should
not print status message on stderr, but rather return the status of
the key binding operation.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2013-07-08 16:27:57 +02:00
Joachim Nilsson
897a98be55 Export el_del_char() 2013-07-08 16:21:54 +02:00
Joachim Nilsson
111fc5e1fb readline(): Check custom key bindings as well.
Make sure to also check custom key bindings.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2013-07-08 16:21:29 +02:00
Joachim Nilsson
8e81add050 readline(): Check common signals first.
Make sure to check common signals first to prevent other interpretations.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
2013-07-08 16:20:01 +02:00
Joachim Nilsson
088dc1d1b2 Move handy macros to global header file, useful when binding keys. 2011-01-06 10:41:07 +01:00
Joachim Nilsson
c59c62951f Update Debian rules file with configure and stamps 2011-01-06 10:40:29 +01:00
Joachim Nilsson
0646b511ab Update README and bump version to 1.14.0 for release. 2010-08-12 16:58:36 +02:00
Joachim Nilsson
4f134f1025 Reduce tgetent() buffer size from 2048 to 1024. 2010-08-12 16:27:10 +02:00
Joachim Nilsson
850e36f9db Fix SIGFPE regression in tty_info() introduced in rl_reset_terminal() commit.
When adding support for rl_reset_termial() the tty_info() code was also
refactored.  This however led to the introduction of a bug that caused
tty_cols to be set to zero.  This in turn caused c_possible() to fail
with SIGFPE in el_print_columns().

Regression was introduced in 1c89c9886c
2010-08-12 16:20:29 +02:00