Commit Graph

476 Commits

Author SHA1 Message Date
Timothy Stack
3b0168025d [cmds] add support for hiding files 2020-10-28 21:18:57 -07:00
Timothy Stack
579e4274f9 [files] initial impl for opening archives 2020-10-28 21:17:57 -07:00
Timothy Stack
9f524136bd [fs] remove old filesystem impl 2020-10-20 22:55:46 -07:00
Timothy Stack
276f71423e [readline] add alternate enter command 2020-09-30 21:55:37 -07:00
Timothy Stack
ee572a2c86 [init] fix an issue with input not being taken when an empty file is loaded 2020-09-16 14:05:56 -07:00
Timothy Stack
dbe252c70c [docs] some more doc stuff 2020-09-15 15:45:29 -07:00
Timothy Stack
bbf06e78ba [init] delay initial command execution until some files are loaded
Fixes #764
2020-09-15 15:44:29 -07:00
Timothy Stack
ce0383dee1 [build] fix some warnings 2020-09-11 23:10:11 -07:00
Timothy Stack
f3d172c831 [keymap] add a french keymap 2020-09-09 22:16:06 -07:00
Timothy Stack
815a05577e [keymap] suggest the config option to set for an unknown keystroke
Also, add a unicode green-check/red-X mark for the success/error
message for commands.
2020-09-05 14:41:05 -07:00
Timothy Stack
8734795505 [keymap] handle unicode keys and add UK keymap
Fixes #392
2020-09-04 14:39:04 -07:00
Timothy Stack
84a7079e3f [main] capture stderr only after initscr() and fix curl configure detection 2020-09-02 15:39:27 -07:00
Timothy Stack
f23791af18 [internals] ignore failure to open file 2020-05-09 12:05:45 -07:00
Timothy Stack
8413dd13d8 [config] add configs directory 2020-05-07 07:08:59 -07:00
Timothy Stack
9b28a90ab0 pay attention to the result of rebuild_index() 2020-04-25 15:43:31 -07:00
Timothy Stack
7e538c85f9 [tests] try to fix breakage 2020-04-25 13:30:28 -07:00
Timothy Stack
8a0193691f ignore stdin when it is from /dev/null 2020-04-25 13:19:41 -07:00
Timothy Stack
3da3ec799a [session] allow the name 2020-04-25 07:32:05 -07:00
Timothy Stack
56a341f7f8 [view_curses] colors
Defect Number:
    Reviewed By:
   Testing Done:
2019-08-07 09:46:19 -07:00
Timothy Stack
9a05b9d186 [config] pay attention to XDG_CONFIG_HOME
Fixes #105
2019-08-01 07:14:47 -07:00
Timothy Stack
07cc749c50 [stdin-capture] change save limit to 10MB 2019-07-31 10:11:23 -07:00
Timothy Stack
e442f84e80 [textview] pause loading of files by pressing =
Fixes #670
2019-07-30 06:28:42 -07:00
Timothy Stack
63dba408ec [stdin] Keep the stdin piper file in .lnav so that it can be reopened
When piping the output of a program into lnav, the data would
be dumped to the terminal on exit so that it would not be
lost.  Since that is a bit noisy, the temp file used to store
the data is now left in .lnav so that it can be reopened later.
Older stdin captures are automatically removed after a day.

Also took the opportunity to start using filesystem::path more.

Fixes #436
2019-07-29 22:18:32 -07:00
Timothy Stack
e6590e94e2 [highlight] fix highlights
Fix #667
2019-07-24 13:37:05 -07:00
Timothy Stack
02c53976b4 Some refactoring for the line buffer and other cleanups
Fixes #649
2019-06-15 06:32:02 -07:00
Timothy Stack
b5c6ed6240 [rebiuld] fix an issue when a text file is truncated 2019-05-23 21:21:39 -07:00
Timothy Stack
0918063640 [cleanup] some modernization 2019-05-21 22:14:36 -07:00
Timothy Stack
1fc24ecabf [bin2c] improve building of data files that are incorporated into the binary 2019-05-15 09:13:56 -07:00
Timothy Stack
fb7d6eafaf [build] some refactoring of files 2019-05-08 05:30:59 -07:00
Timothy Stack
06d1098211 [config] initial support for themes
For #422

Still more to do
2019-05-03 13:50:19 -07:00
Timothy Stack
78d80fddd5 [cli] add -r flag for recursively loading files from a directory hierarchy
Fixes #431
2019-03-14 22:24:57 -07:00
Timothy Stack
21c5c52843 [format] allow multiple log format patterns per log file
This tries to address #624
2019-03-13 16:37:41 -07:00
Timothy Stack
02b9e13343 [filters] add the number of hits for each filter in the editor
Might be useful to know the number of hits for a given filter.
2019-02-15 09:22:32 -08:00
Timothy Stack
1e795c1e4a [ui] move filter editor help to separate status bar
The help is unreadable when the terminal width is
small.
2019-02-13 21:54:40 -08:00
Timothy Stack
153b59ea8a [status] some fixes for the bottom status bar
Fixes #603
Fixes #578
2019-02-05 07:30:57 -08:00
Timothy Stack
4381c23641 some build and cleanup 2019-01-13 19:14:26 -08:00
Timothy Stack
dcccebe797 [sql] add some help for regexp_capture()
Fixes #593
2019-01-13 19:02:50 -08:00
Timothy Stack
814ad03ec9 [view] keep a history of view positions
Fixes #577
2018-12-14 06:18:56 -08:00
Timothy Stack
5769bcbb4a whiff
missed refreshing patch
2018-12-02 09:34:36 -08:00
Timothy Stack
42be76c3ba [readline] fix some broken shortcuts
Defect Number:
    Reviewed By:
   Testing Done:
2018-12-02 07:58:30 -08:00
Timothy Stack
f2b9988c95 [internal] capture stderr while in curses and log it
Fixes #582
2018-11-29 07:16:25 -08:00
Timothy Stack
49dce3cec2 [readline] fix escaping out of prompt 2018-11-20 08:15:58 -08:00
Timothy Stack
5c6cc5fe2a [readline] pressing escape should exit the command prompt
Fixes #316
2018-11-15 06:43:28 -08:00
Timothy Stack
2345a32423 [filter] add panel that shows the set of filters
Initial version, still needs some cleanup
2018-11-09 09:45:19 -08:00
Timothy Stack
b1a6d06490 [lss] refactor the force flag during indexing and some other stuff 2018-10-25 21:26:58 -07:00
Timothy Stack
2589345e5c [perf] improve initial indexing times 2018-10-17 07:03:33 -07:00
Timothy Stack
ac7ae1275a [cmds] add :redirect-to command for redirecting the output of commands in scripts
Related to #551
2018-10-12 07:12:35 -07:00
Timothy Stack
5f5e2d5c4e [cleanup] prune some includes and some other cleaning
Defect Number:
    Reviewed By:
   Testing Done:
2018-10-11 05:50:28 -07:00
Timothy Stack
9664b015c6 [textview] preserve location in view when changing filters
Defect Number:
    Reviewed By:
   Testing Done:
2018-10-08 07:43:08 -07:00
Timothy Stack
686ce639a0 [build] use cmath instead of math.h
Defect Number:
    Reviewed By:
   Testing Done:
2018-10-02 22:01:18 -07:00
Timothy Stack
f65df7c762 [readline] tweak fuzzy matching threshold
Change the threshold for cutting off the remaining fuzzy matches
that was added for #541

Also, fix an error when filtering is added when viewing
the tail of the log.
2018-09-29 00:20:45 -07:00
Timothy Stack
b1ff6b3a3b [json-log] fix some inconsistencies with json logs
Fill some gaps brought up in #535
2018-08-21 11:10:03 -07:00
Timothy Stack
00ed12557b [keymap] add more keys to the keymap 2018-08-12 08:37:16 -07:00
Timothy Stack
bc8e51914a [hotkey] the "P" hotkey was not toggling the view
Fixes #522
2018-06-07 06:26:07 -07:00
Timothy Stack
6bfd158e49 [logline] check for SQL keywords in column names 2018-05-27 07:59:24 -07:00
Timothy Stack
5689984702 [yajlpp] use pointer to member over nullobj() 2018-05-25 06:32:01 -07:00
Timothy Stack
4ccae48aea [bookmarks] add support for tags and comments for log lines
Initial work for #446 and #447
  TODO: filtering on tags/comments

Also did a bunch of clang-tidy cleanups and improvements to
the online help.
2018-05-17 07:06:50 -07:00
Timothy Stack
7fb881222d [pretty] highlight log messages in the pretty view as in the normal log view 2018-05-10 06:44:03 -07:00
Nicolas Werner
5594120f1a Use CTRL macro from readline instead of CEOF from ttydefaults.h
The ttydefaults.h header is not available on musl. Readline provides the
same functionality with its CTRL macro and it makes the intent of the
code a bit clearer (that we check for CTRL-D).
2018-04-26 14:54:25 +02:00
Timothy Stack
7c5fc44f7d [view_curses] fix highlighting when a line contains unicode
Take into account unicode codepoint lengths when adjusting
attribute ranges
2018-04-04 07:41:09 -07:00
Timothy Stack
9f91d3b447 [log-view] display the unique parts of the file name instead of just the base
Instead of just displaying the base name of the file, try to include some
additional parts of the path that make a unique string.
2018-04-03 07:36:09 -07:00
Phil Hord
eee7d0ddfc Squash a bunch of signed/unsigned warnings 2018-03-29 10:49:38 -07:00
Timothy Stack
ef34a6aaaf [search] display lines matching the search in preview instead of jumping to the first
Jumping around can be disruptive, instead show matches in
the preview window.
2018-03-28 07:25:10 -07:00
Timothy Stack
36932b148d [hotkeys] cleanup the last commit 2018-03-28 05:35:37 -07:00
Timothy Stack
8257f188cb [hotkeys] change the filename hotkey to left/right arrow 2018-03-27 22:11:57 -07:00
Timothy Stack
7d7060ae4c [generic_log] fix recognition for generic logs
The generic format picks up extra text in the timestamp, which
caused the date time scanner to reject some matches.  I think
it's okay to allow for some trailing junk, so it no longer
ensures the size of the match is the same as the input.
2018-02-04 22:21:18 -08:00
Timothy Stack
bdcfc5cfdd [misc] rounding some corners 2018-01-08 10:03:11 -08:00
Timothy Stack
75ccb8ca4f [layout] fix a crash with a small window 2018-01-07 22:17:27 -08:00
Timothy Stack
74b58ed9fc [highlights] allow the highlight color to be specified in log formats
Defect Number:
    Reviewed By:
   Testing Done:
2017-12-29 06:51:09 -08:00
Timothy Stack
b5f5b4137c [search] redo search after filtering
Fixes #480
2017-12-04 08:52:40 -08:00
Timothy Stack
f25980df03 [ui] rework the default colors change
The default colors change resulted in some parts of the lnav
UI being colored incorrectly.  I've reworked it a bit so that
the ansi color pairs are preserved and the default colors are
only used with the color pairs for roles.  I've also replaced
references to ansi colors with roles in a few places to make
things work consistently.
2017-12-02 22:11:34 -08:00
Suresh Sundriyal
4483722b1d Fix the __clang__ macro. 2017-10-28 16:10:03 -07:00
Suresh Sundriyal
217d365672 Redefine _WCHAR_H_CPLUSPLUS_98_CONFORMANCE_ only on OpenBSD 2017-10-28 15:11:15 -07:00
Suresh Sundriyal
1a7e2fee9b Redefine _WCHAR_H_CPLUSPLUS_98_CONFORMANCE_ only if needed. 2017-10-28 14:26:35 -07:00
Suresh Sundriyal
72f3d7951b Don't redefine rl_completer_word_break_characters 2017-10-28 13:26:29 -07:00
Suresh Sundriyal
23c1f7ba4f [OpenBSD] Define _WCHAR_H_CPLUSPLUS_98_CONFORMANCE_ only when using Clang. 2017-10-28 13:17:54 -07:00
Suresh Sundriyal
0c88eeeb07 Fix lnav builds on OpenBSD.
* Remove all the wordexp related unused headers and code.
* stdout does not appear to be reassignable on OpenBSD.
* defining _WCHAR_H_CPLUSPLUS_98_CONFORMANCE_ seems to fix the const
  correctness related redefinitions between wchar.h imported from
  the system libc and the one imported by clang++ STL.
2017-10-28 05:21:02 -07:00
Timothy Stack
d18b344489 [perf] avoid an initial forced index rebuild
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-25 06:55:07 -07:00
Timothy Stack
867504b2b5 [build] try to fix some tests
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-23 15:57:24 -07:00
Timothy Stack
8ea51a6fd8 [formats] support for CSV/TSV log formats
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-23 07:11:21 -07:00
Timothy Stack
16fd7ec785 [help] remove old command help and add some more filesystem extensions 2017-04-16 15:07:41 -07:00
Timothy Stack
5e8d6aa3a8 [session] add hidden fields to the session
Fixes #433
2017-04-15 21:11:11 -07:00
Timothy Stack
4cedde9a43 [help] add builtin help to the main help text as a reference
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-14 22:49:36 -07:00
Timothy Stack
abd566cb08 [readline] make search tab-completion case-insensitive 2017-04-13 06:15:29 -07:00
Timothy Stack
a973f7f934 [misc] some more miscellaneous bugs
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-12 15:54:54 -07:00
Timothy Stack
05730274ed [prev-mark] jumping to the first bookmark wasn't always working 2017-04-12 07:32:11 -07:00
Timothy Stack
aa21234164 [hist] need to rebuild hist to reflect marks
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-11 07:25:54 -07:00
Timothy Stack
7033b51b41 fix potential crash when quitting 2017-04-10 23:21:14 -07:00
Timothy Stack
aae3cf4d14 [log_vtab_manager] fix lookup_impl() 2017-04-09 02:32:07 -07:00
Timothy Stack
fea3cb83d9 [sql] preview table definition
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-09 01:57:19 -07:00
Timothy Stack
914f4cf4bb [filter-out] show a preview of the filter effects by highlighting matches in red
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-07 23:11:57 -07:00
Timothy Stack
851bd183b3 [perf] some performance tweaks 2017-04-05 21:42:54 -07:00
Timothy Stack
78119dc9f1 fixing some minor issues
Fixes #255
2017-04-05 07:05:19 -07:00
Timothy Stack
4954817741 [crash] pressing i/I when not in the log view
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-02 07:47:51 -07:00
Timothy Stack
00ebd10d71 [cmds] do a dry-run of a command to check for errors
Defect Number:
    Reviewed By:
   Testing Done:
2017-04-02 07:17:31 -07:00
Timothy Stack
411ea1fbee [help] show help text for SQL functions
Defect Number:
    Reviewed By:
   Testing Done:
2017-03-31 07:01:11 -07:00
Timothy Stack
cd76eae5b8 [build] convert some C files to C++
Defect Number:
    Reviewed By:
   Testing Done:
2017-03-26 21:01:49 -07:00
Timothy Stack
6fcfd35395 [sql] add "search" column to the lnav_views table
Fixes #388
2017-03-26 07:28:08 -07:00
Timothy Stack
8776f6a703 [sql] do some minimal parsing/annotation of SQL statements
Defect Number:
    Reviewed By:
   Testing Done:
2017-03-26 06:02:53 -07:00
Timothy Stack
c0684a97cc [sql] add a regexp_capture tablue-valued function
Fixup the release makefile a bit.
2017-03-15 17:01:58 -07:00