Johan Walles
190e362f14
Update a test
...
So it doesn't get special treatment from being identified as a heading.
2024-01-10 17:19:58 +01:00
Johan Walles
ce89f69b1c
Test highlighing man page headers
...
Fails.
2024-01-10 17:17:14 +01:00
Johan Walles
2e6d79a177
Use the right index
2024-01-10 17:00:28 +01:00
Johan Walles
a72423cffc
Add a test
2024-01-10 16:50:20 +01:00
Johan Walles
96bf1394fc
Optimize out a unicode operation in the common case
...
Common case = no backspaces in the string.
2024-01-10 16:50:20 +01:00
Johan Walles
fe0e5493ab
Headings do not start with whitespace
2024-01-10 16:50:20 +01:00
Johan Walles
4ccc36732d
Fix a heading identification bug
2024-01-10 16:50:20 +01:00
Johan Walles
3b16284ed9
Use GenericHeading for man page headings
2024-01-10 16:50:20 +01:00
Johan Walles
90b4e92e76
Add man page headings test
2024-01-10 16:50:20 +01:00
Johan Walles
e823d0263a
Use 16M color when requested
...
Before this change we used 8 colors when asked for 16M.
2024-01-10 16:48:42 +01:00
Johan Walles
b5f9b88c31
Fix wrapping backwards search
2024-01-10 14:41:21 +01:00
Johan Walles
ab20550d45
Fix search problem on not-found mode
...
Fixes #182 , but there are still related issues when searching backwards
and wrapping after not-found.
2024-01-10 13:37:45 +01:00
Johan Walles
625c94feec
Fix hang searching backwards
...
Solves the hang in #182 , but we still don't find anything on the way
back so not there yet.
2024-01-10 13:15:43 +01:00
Johan Walles
a9d1ad542d
Move gotoLineString to where it should be
...
It only lives as long as the GotoLine mode does, so it should be part of
that struct.
2024-01-09 17:28:49 +01:00
Johan Walles
98b83c45d6
Merge branch 'johan/mark-jump'
...
Fixes #175 .
2024-01-09 15:44:08 +01:00
Johan Walles
b2019308e1
Not needed, remove it
2024-01-09 15:41:44 +01:00
Johan Walles
0f60fb4f45
Fix the help text
2024-01-09 15:39:59 +01:00
Johan Walles
a9fbc3f681
Fixups after testing
2024-01-09 15:37:42 +01:00
Johan Walles
4867b2c2ed
Implement jumping to marks
2024-01-09 15:26:16 +01:00
Johan Walles
ab10a82b6c
Add a mark setting mode
2024-01-09 15:02:43 +01:00
Johan Walles
8fb912e261
Initial marks commit
2024-01-09 14:52:00 +01:00
Johan Walles
a38c6344b6
Merge branch 'johan/pager-control'
...
This moves code for different pager moves out into separate files.
2024-01-09 14:45:39 +01:00
Johan Walles
900042183a
Ponderings around naming
2024-01-09 14:45:17 +01:00
Johan Walles
eaa06ac3cc
Simplify a test
2024-01-09 14:40:40 +01:00
Johan Walles
2561e6a114
Fix wrapping scroll issue
2024-01-09 14:25:50 +01:00
Johan Walles
07e8bf6142
Pass all tests
2024-01-09 14:14:39 +01:00
Johan Walles
f22f6e7658
Silence false positive linter warnings
2024-01-09 14:10:44 +01:00
Johan Walles
8e81a04188
Make the tests compile
2024-01-09 13:52:59 +01:00
Johan Walles
1164972796
Add a not found pager mode
2024-01-09 13:47:04 +01:00
Johan Walles
2fbf74559f
Add a go-to-line mode
2024-01-09 13:38:52 +01:00
Johan Walles
dde3525a2b
Implement viewing mode
2024-01-09 13:31:43 +01:00
Johan Walles
74b84eed34
Start extracting pager modes
2024-01-09 12:00:47 +01:00
Johan Walles
f186b736da
Add zstd compression support
...
I like zstd.
2024-01-08 21:25:15 +01:00
Johan Walles
4a77e96159
Merge branch 'johan/zopen2'
...
With this change in place we now decompress using Go code rather than
forking off decompression programs.
As a side effect, this will make it possible (although maybe not
recommended) to use moar as a decompression program early in a pipeline:
moar something.gz | grep hello
Fixes https://github.com/walles/moar/issues/177 , or at least what that
issue has in its title.
2024-01-08 14:08:10 +01:00
Johan Walles
a579da4ccc
Revive xz support
2024-01-08 14:07:30 +01:00
Johan Walles
c6f6cfb7e7
Support gzip and bzip2 using Go's stdlib
2024-01-08 14:03:36 +01:00
Johan Walles
b2e223e381
Add a decompressing-while-piping test
2024-01-08 13:44:10 +01:00
Johan Walles
8c8b82f166
Use ZOpen() instead of os.Open()
2024-01-08 13:43:46 +01:00
Johan Walles
953d7382b0
Merge branch 'johan/linenumber'
...
This moves line number handling into its own package.
2024-01-08 12:59:19 +01:00
Johan Walles
a830f921b5
Update a comment
2024-01-08 12:58:58 +01:00
Johan Walles
6852018ece
Update a test to the new reality
2024-01-08 12:52:47 +01:00
Johan Walles
2a80a04243
Fix a faulty test
2024-01-08 12:50:34 +01:00
Johan Walles
b40c4bddf9
Always get status from reader
2024-01-08 12:41:51 +01:00
Johan Walles
c2d3e63ad4
Make another test pass
2024-01-07 23:40:12 +01:00
Johan Walles
6cf4d6b8ab
Fix another test
...
I don't understand the difference here, but the old one failed and the
new (even) more obvious one passes.
2024-01-07 23:30:15 +01:00
Johan Walles
ba3241e43e
Fix a broken assertion
2024-01-07 23:20:59 +01:00
Johan Walles
1c58d83bd3
Make some more tests pass
2024-01-07 23:17:34 +01:00
Johan Walles
d2b3fad36b
Parameterize another test
...
For great results presentations.
2024-01-07 22:48:14 +01:00
Johan Walles
f81ba2b216
Make another test pass
2024-01-07 22:44:32 +01:00
Johan Walles
ac6793f7a9
Make one test pass
2024-01-07 15:21:00 +01:00