120 Commits

Author SHA1 Message Date
Kovid Goyal
98f6e24106
Move block outside try/except as it doesnt need to be in there 2022-06-06 08:17:15 +05:30
Kovid Goyal
cd7751681d
hints kitten: Fix surrounding quotes/brackets and embedded carriage returns not being removed when using line number processing
Fixes #5170
2022-06-05 18:07:16 +05:30
pagedown
288d16f7be
Docs: Minor tweaks to the help documentation of hints kitten 2022-04-24 17:18:45 +08:00
Kovid Goyal
e522095fae
... 2022-03-26 07:39:16 +05:30
pagedown
746cb3684a
Eliminate flickering when hints kitten exits 2022-03-25 22:53:38 +08:00
pagedown
16c6545e93
Report overlay ready in case of no match 2022-03-25 22:52:35 +08:00
Kovid Goyal
15e3e8d8b1
typo 2022-03-25 16:18:00 +05:30
Kovid Goyal
3c67e991c2
Allow defining actions to take when pasting
Fixes #4873
2022-03-24 17:22:46 +05:30
Kovid Goyal
bfb8532c52
Jump through the hoops needed to ensure error reporting is done in case of early termination of kittens that use overlay ready notifications 2022-03-24 08:49:36 +05:30
Kovid Goyal
6dc1617429
Avoid flicker when starting kittens such as the hints kitten
Fixes #4674
2022-03-23 15:55:11 +05:30
Kovid Goyal
cb4a9d89cf
Cleanup linenum matching and add some tests 2022-02-23 23:06:19 +05:30
Kovid Goyal
7800c598f6
hints kitten: Fix a regression that broke recognition of path:linenumber:colnumber
Fixes #4675
2022-02-23 22:38:54 +05:30
Kovid Goyal
6bfb6da0ad
Make the regex for sgr stripping tighter 2022-02-15 22:33:51 +05:30
Kovid Goyal
56a5738018
Remove unused code 2022-02-15 22:22:07 +05:30
Kovid Goyal
919667129f
hints kitten: Avoid double scan of input text 2022-02-15 22:21:31 +05:30
Kovid Goyal
53716c084b
hints kitten: Strip prompt mark escape codes 2022-02-15 22:04:10 +05:30
pagedown
d40e6a9ece
hints kitten: Match and strip Unicode single and double quotes 2022-02-11 14:59:35 +08:00
pagedown
4a3ed62809
Refactor: More f-string for kittens 2022-01-29 20:23:34 +08:00
Kovid Goyal
b32edf54f8
hints kitten: Document how to choose the empty hint for multi key hints 2022-01-15 15:17:30 +05:30
Kovid Goyal
b2bfc4408e
Fix common single letter extension files not being detected
Fixes #4491
Fixes #4492
2022-01-10 14:20:18 +05:30
Kovid Goyal
dae8ae33f0
hints kitten: Fix matching of filenames enclosed in quotes or brackets not stripping the surrounding quotes properly. Fixes #4419 2022-01-04 10:58:31 +05:30
pagedown
98e44a8907
Unify resolution of absolute paths or config dir paths 2021-12-09 20:43:07 +08:00
Kovid Goyal
b7a28afe7e
missed a couple of options 2021-11-21 22:41:30 +05:30
Kovid Goyal
f3376601f2
Mark various options in text correctly 2021-11-21 22:37:11 +05:30
Kovid Goyal
d090db380f
Add more type annotations 2021-10-27 13:26:18 +05:30
Kovid Goyal
4494ddd8ff
mypy: Turn on return value checks
Its a shame GvR is married to "return None"
https://github.com/python/mypy/issues/7511
2021-10-26 22:39:14 +05:30
Kovid Goyal
6546c1da9b
run pyupgrade to upgrade the codebase to python3.6 2021-10-21 12:43:55 +05:30
Kovid Goyal
31e623afb3
Add support for Unicode 14
Fixes #3542
2021-10-04 14:00:35 +05:30
Kovid Goyal
89f8151579
hints kitten: Fix a regression that caused using the default open program to trigger open actions instead of running the program
Fixes #3968
2021-08-23 11:56:16 +05:30
Kovid Goyal
8cfb1efb01
hints kitten: Make the --program option work with --linenum-action=self
Fixes #3931
2021-08-15 08:27:25 +05:30
Kovid Goyal
1bd39ff935
Use new URL scheme and define the kitty website centrally as much as possible 2021-07-27 09:03:11 +05:30
Kovid Goyal
93e3e4d2b1
Also strip \r from marked text 2021-07-19 18:12:29 +05:30
Kovid Goyal
3633049ba5
Forgot to include \r in the url regex 2021-07-19 18:09:00 +05:30
Kovid Goyal
c566ed4643
hints kitten: Detect paths and hashes that appear over multiple lines
Fixes #3845
2021-07-19 17:35:48 +05:30
Reto Schnyder
926c3540ff Fix unbound variable in hyperlink handling 2021-04-19 14:19:13 +02:00
Kovid Goyal
945cbca387
hints kitten: When using the linenumber action with a background action, preserve the working directory
Fixes #3352
2021-02-27 09:14:12 +05:30
Kovid Goyal
30c7ff341f
DRYer 2021-02-27 09:10:16 +05:30
Kovid Goyal
027c5a57f1
Work on porting kittens to use new key infrastructure
Also move type definitions into their own module
2021-01-16 20:52:14 +05:30
Kovid Goyal
ff96036f62
Better window title when choosing tabs/OS windows 2020-11-21 14:58:08 +05:30
Kovid Goyal
d8790a4628
Make the help text for --linenum-action less confusing 2020-11-13 23:53:26 +05:30
Kovid Goyal
b04b0c670d
Fix #3010
Probably ancient version of Python
2020-10-06 12:09:47 +05:30
Kovid Goyal
12c9d8d8f8
Delay load the ipaddress module 2020-10-06 06:50:17 +05:30
Sighery
10533c3eba Hints kitten: validate IPs with ipaddress
On the initial commit of this feature, IPs were just matched with a
very simple regex that prioritised simplicity/readability over
accuracy.

This commit adds a postprocessor for ip matches that makes use of
Python's `ipaddress` in the standard library to validate all the IP
matches.

This way we don't need huge and complex regex patterns to match _and_
validate the IPs, and we can just use `ipaddress` to abstract us from
implementing all the validation logic into the regex pattern.
2020-10-05 20:11:25 +02:00
Sighery
b4415c90f9 Hints kitten: add support for IPs (v4 and v6)
It selects v4 and v6 IPs with a simple regex that doesn't actually
check for the validity of the IPs.
2020-10-05 20:11:22 +02:00
Kovid Goyal
12bbe5459d
Allow selecting hyperlinks via the hints kitten 2020-09-24 13:21:15 +05:30
Kovid Goyal
8c7886d429
Add a changelog entry for the last PR 2020-08-03 09:00:19 +05:30
Jay Han
ee0b70f51b allow users to choose hint colors 2020-08-02 15:33:17 -07:00
Trygve Aaberge
d509a4fa8c Expand ~ in the path argument for linenum in hints
Fixes #2822
2020-07-02 01:01:14 +02:00
Kovid Goyal
19df7b94ea
Clarify documentation a bit 2020-06-16 09:53:08 +05:30
Kovid Goyal
a3ecc79f0d
Dont actually need -- since kitty's option processing code is smart enough to stop looking for options after the first non-optional argument 2020-06-16 09:31:42 +05:30