Skip to content

Commit 6b08d1c

Browse files
committed
0.7.9
1 parent a3dc835 commit 6b08d1c

File tree

1 file changed

+43
-22
lines changed

1 file changed

+43
-22
lines changed

README.md

Lines changed: 43 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<p align="center">
2-
<img src="/img/logo.jpg">
2+
<img src="/img/logo.png">
33
</p>
44

55
<p align="center">
@@ -8,7 +8,7 @@
88
<a href="https://goreportcard.com/report/github.com/Lifailon/lazyjournal"><img src="https://goreportcard.com/badge/github.com/Lifailon/lazyjournal" alt="Go Report"></a>
99
<a href="https://pkg.go.dev/github.com/Lifailon/lazyjournal"><img src="https://pkg.go.dev/badge/github.com/Lifailon/lazyjournal.svg" alt="Go Reference"></a>
1010
<a href="https://github.com/Lifailon/lazyjournal/blob/rsa/LICENSE"><img title="License"src="https://img.shields.io/github/license/Lifailon/lazyjournal?logo=readme&color=white"></a>
11-
<!-- <a href="https://github.com/avelino/awesome-go"><img src="https://awesome.re/mentioned-badge.svg" alt="Mentioned in Awesome Go"></a> -->
11+
<a href="https://github.com/avelino/awesome-go"><img src="https://awesome.re/mentioned-badge.svg" alt="Mentioned in Awesome Go"></a>
1212
<br>
1313
<a href="https://aur.archlinux.org/packages/lazyjournal"><img title="Arch Linux" src="https://img.shields.io/aur/version/lazyjournal?logo=arch-linux&color=blue&label=AUR"></a>
1414
<a href="https://anaconda.org/conda-forge/lazyjournal"><img title="Conda Forge" src="https://img.shields.io/conda/vn/conda-forge/lazyjournal?logo=anaconda&color=green&label=Conda"></a>
@@ -20,7 +20,20 @@ Terminal user interface for reading logs from `journald`, `auditd`, file system,
2020

2121
This tool is inspired by and with love for [LazyDocker](https://github.com/jesseduffield/lazydocker) and [LazyGit](https://github.com/jesseduffield/lazygit). It is also included in [Awesome-Go](https://github.com/avelino/awesome-go?tab=readme-ov-file#logging), [Awesome-TUIs](https://github.com/rothgar/awesome-tuis?tab=readme-ov-file#development) and [Awesome-Docker](https://github.com/veggiemonk/awesome-docker?tab=readme-ov-file#terminal-ui), check out other useful projects on the repository pages.
2222

23-
![interface](/img/regex.png)
23+
![Regex filtering](/img/regex.png)
24+
25+
26+
<details>
27+
<summary>Screenshots</summary>
28+
<li>Filtering the file log using fuzzy search:</li>
29+
<img src="./img/fuzzy.jpg" alt="Filtering the file log using fuzzy search">
30+
<li>Filtering by timestamp for ssh log from systemd:</li>
31+
<img src="./img/timestamp.jpg" alt="Filtering by timestamp for ssh log from systemd" />
32+
<li>Disabling built-in timestamp in docker logs and filtering by stream:</li>
33+
<img src="./img/docker.jpg" alt="Disabling built-in timestamp in docker logs and filtering by stream" />
34+
<li>Demo file of built-in output coloring for the log:</li>
35+
<img src="./img/coloring.jpg" alt="Demo file of built-in output coloring for the log" />
36+
</details>
2437

2538
## Features
2639

@@ -35,7 +48,7 @@ This tool is inspired by and with love for [LazyDocker](https://github.com/jesse
3548
- Lists all log files in users home directories, as well as descriptor log files used by processes.
3649
- Reading archive logs truncated during rotation (`gz`, `xz` and `bz2` formats), Packet Capture (`pcap` format) and Apple System Log (`asl` format).
3750
- Search and analyze all logs from remote hosts in one interface using [rsyslog](https://www.rsyslog.com) configuration.
38-
- Docker logs, including archive logs, timestamp and all streams.
51+
- Docker logs from the file system or stream, including build-in timestamps and filtering by stream.
3952
- Podman logs, without the need to run a background process (socket).
4053
- Kubernetes pods (need to configure a connection to the cluster via `kubectl` in advance).
4154
- Windows Event Logs via `PowerShell` and `wevtutil`, as well as application logs from Windows file system.
@@ -47,7 +60,7 @@ Supports 4 filtering modes:
4760
- **Default** - case sensitive exact search.
4861
- **Fuzzy** (like `fzf`) - custom inexact case-insensitive search (searches for all phrases separated by a space anywhere on a line).
4962
- **Regex** (like `grep`) - search with regular expression support, based on the built-in [regexp](https://pkg.go.dev/regexp) library, case-insensitive by default (in case a regular expression syntax error occurs, the input field will be highlighted in red).
50-
- **Timestamp** - filter `since` and/or `until` by date and time for `journald`, docker and podman logs from streams. This mode affects the loading of the log (thereby increasing performance) and can be used in conjunction with other filtering modes, so the current log should be reloaded by pressing `Enter` in the current input field.
63+
- **Timestamp** - filter `since` and/or `until` by date and time for `journald` and docker or podman logs in stream mode. This mode affects the loading of the log (thereby increasing performance) and can be used in conjunction with other filtering modes, so the current log should be reloaded by pressing `Enter` in the current input field.
5164

5265
Supported formats for timestamp:
5366

@@ -210,21 +223,24 @@ lazyjournal --version, -v Show version
210223
lazyjournal --audit, -a Show audit information
211224
lazyjournal --tail, -t Change the number of log lines to output (default: 50000, range: 200-200000)
212225
lazyjournal --update, -u Change the auto refresh interval of the log output (default: 5, range: 2-10)
226+
lazyjournal --disable-autoupdate, -e Disable streaming of new events (log is loaded once without automatic update)
213227
lazyjournal --disable-color, -d Disable output coloring
228+
lazyjournal --disable-mouse, -m Disable mouse control support
214229
lazyjournal --disable-timestamp, -s Disable timestamp for docker logs
215-
lazyjournal --command-color, -c Coloring in command line mode
230+
lazyjournal --only-stream, -o Force reading of docker container logs in stream mode (by default from the file system)
231+
lazyjournal --command-color, -c ANSI coloring in command line mode
216232
lazyjournal --command-fuzzy, -f Filtering using fuzzy search in command line mode
217233
lazyjournal --command-regex, -r Filtering using regular expression (regexp) in command line mode
218234
```
219235

220-
Access to all system logs and containers may require elevated privileges for the current user. For example, if a user does not have permission to access the `/var/lib/docker/containers` directory, they will not be able to access history data from the time the container was started, but only from the time the containerization system was started, so the process of reading logs is different.
236+
Access to all system logs and containers may require elevated privileges for the current user. For example, if a user does not have read permission to the directory `/var/lib/docker/containers`, he will not be able to access all archived logs from the moment the container is started, but only from the moment the containerization system is started, so the process of reading logs is different. However, reading in streaming mode is faster than parsing json logs from the file system.
221237

222238
Information in the subtitle of the `Logs` window:
223239

224-
- `tail` - maximum number of log lines to load.
225-
- `update` - current output auto-update status (disabled when manually scrolling the output).
226-
- `interval` - auto-update interval for output in seconds (file logs are updated only when there are changes).
227-
- `color` - whether the output coloring mode is currently enabled or disabled.
240+
- `tail` - maximum number of log lines to output (affects log loading performance).
241+
- `auto-update (interval)` - current mode of operation for automatic display of new events (disabled by manually scrolling the log output or using the `Ctrl+U` keyboard shortcut) and update interval (file logs are updated only when there are changes).
242+
- `docker` - displays the current mode for loading the container log (stream mode from the docker api or in json format from the file system) and stream display mode (all, stdout or stderr only).
243+
- `color` - displays the status (enabled or disabled) of the output coloring for the log.
228244

229245
### Command-line mode
230246

@@ -247,23 +263,28 @@ Mouse control is supported for window selection, history, list scrolling and his
247263

248264
List of all used keyboard shortcuts:
249265

250-
- `F1` - show help on hotkeys.
251-
- `Tab` - switch between windows.
266+
- `F1` or `?` - show help on hotkeys.
267+
- `Tab` - switch to next window.
252268
- `Shift+Tab` - return to previous window.
253-
- `Enter` - selection a journal from the list to display log output.
254-
- `Left/Right` - switch between journal lists in the selected window.
255-
- `<Up/PgUp>` and `<Down/PgDown>` - move up and down through all journal lists and log output, as well as changing the filtering mode in the filter window.
269+
- `/` - go to the filter window from the current list window or logs window.
270+
- `Esc` - clear text in the current filter window or close help.
271+
- `Enter` - load a log from the list window or return to the previous window from the filter window.
272+
- `<Left/h>` and `<Right/l>` - switch between journal lists in the selected window.
273+
- `<Up/PgUp/k>` and `<Down/PgDown/j>` - move up and down through all journal lists and log output, as well as changing the filtering mode in the filter window.
256274
- `<Shift/Alt>+<Up/Down>` - quickly move up and down through all journal lists and log output every `10` or `100` lines (`500` for log output).
257-
- `<Shift/Ctrl>+<U/D>` - quickly move up and down (alternative for macOS).
258-
- `Ctrl+A` or `Home` - go to top of log.
275+
- `<Shift/Alt/Ctrl>+<k/j>` - quickly move up and down (like Vim and alternative for macOS).
276+
- `Ctrl+A` or `Home` - go to the top of the log.
259277
- `Ctrl+E` or `End` - go to the end of the log.
260278
- `Alt+Left/Right` - change the number of log lines to output (default: `50000`, range: `200-200000`).
261279
- `Shift+Left/Right` - change the auto refresh interval of the log output (default: `5`, range: `2-10`).
262-
- `Ctrl+T` - enable or disable timestamp for Docker logs.
263-
- `Ctrl+Q` - enable or disable built-in output coloring.
264-
- `Ctrl+S` - enable or disable coloring via [tailspin](https://github.com/bensadeh/tailspin).
280+
- `Ctrl+D` - change read mode for docker logs (streams only or json from file system).
281+
- `Ctrl+S` - change streams display mode for docker logs (all, stdout or stderr only).
282+
- `Ctrl+T` - enable or disable built-in timestamp and stream type for docker logs.
283+
- `Ctrl+W` - enable or disable ANSI coloring for output.
284+
- `Ctrl+N` - enable or disable coloring via [tailspin](https://github.com/bensadeh/tailspin).
285+
- `Ctrl+U` - disable streaming of new events (log is loaded once without automatic update).
286+
- `Ctrl+Q` - update the current log output manually.
265287
- `Ctrl+R` - update all log lists.
266-
- `Ctrl+W` - clear text input field for filter to quickly update current log output.
267288
- `Ctrl+C` - exit.
268289

269290
## Build

0 commit comments

Comments
 (0)