70 Commits

Author SHA1 Message Date
Kovid Goyal
0db9b882fe Cleanup previous PR 2025-03-19 21:25:02 +05:30
arne314
40ef6b4f37 config: number with unit for min contrast ratio 2025-03-14 14:05:34 +01:00
Kovid Goyal
d22c8f5878 Nicer reporting of errors when using geninclude 2025-02-05 16:24:38 +05:30
Kovid Goyal
da1626090a Update codebase to Python 3.10 using pyupgrade 2025-02-03 10:56:50 +05:30
Kovid Goyal
d7207edf2b DRYer 2025-01-07 11:54:06 +05:30
Kovid Goyal
69aead6d3d query_terminal: Add support for reporting name of the OS the terminal emulator is running on
Fixes #8201
2025-01-07 08:21:53 +05:30
Kovid Goyal
1eeea70c7a Allow dynamically generating configuration by running an arbitrary program using the new geninclude directive 2025-01-06 19:00:01 +05:30
Kovid Goyal
76ebc591db Make the effective configuration file for the kitty process available in the cache directory
This can be parsed by kittens to load effective settings, thereby making
things like --override and reloading of config also affect kittens that
read kitty config. Still to be implemented on the kitten side.
2025-01-05 15:28:30 +05:30
Kovid Goyal
fc13b06b35 Implement proper unit bezier easing function
Code based on WebKit
https://github.com/WebKit/WebKit/blob/main/Source/WebCore/platform/graphics/UnitBezier.h
2024-07-18 22:25:02 +05:30
Kovid Goyal
3c4f2aa1b8 shlex.split -> shlex_split 2023-12-02 15:17:08 +05:30
Kovid Goyal
77292a16d6 Make shebangs consistent
Follow PEP 0394 and use /usr/bin/env python so that the python in the
users venv is respected. Not that the kitty python files are meant to be
executed standalone anyway, but, whatever.

Fixes #6810
2023-11-11 08:32:05 +05:30
Kovid Goyal
4ffb22199b Cleanup previous PR 2023-09-03 18:59:37 +05:30
Jake Stewart
f0e9311cc4 conform to style guide 2023-09-03 17:15:26 +08:00
Jake Stewart
2113a22f11 add line break syntax to python config parser 2023-09-03 16:37:34 +08:00
Kovid Goyal
d550aef792 Fix #6056 2023-02-25 08:49:49 +05:30
Kovid Goyal
7fe5d7b58f Replace isort with ruff 2023-01-09 16:47:42 +05:30
pagedown
30b25709d2 Fix the base path for envinclude 2022-12-05 14:53:26 +08:00
Kovid Goyal
d7d96c2e7b When using the include directive in kitty.conf make the environment variable KITTY_OS available for OS specific config 2022-12-04 21:03:24 +05:30
Kovid Goyal
e64b1ba67c Start work on remote control passwords 2022-08-10 12:36:04 +05:30
Andrew Marshall
90477825c2 Make globinclude sort files before loading
`Path.glob` gives no guarantee about the order results are returned in.
This means that if files included by `globinclude` override each other,
the resulting config was non-deterministic. Resolve this by sorting the
results from `glob` to give consistent, well-defined order.
2022-06-17 18:50:16 -04:00
Kovid Goyal
ffa79d731c Allow configuring the ssh kitten via env vars 2022-03-05 12:29:55 +05:30
Kovid Goyal
262ba0197d Allow using - as a synonym for /dev/stdin when reading the config 2022-03-05 08:07:32 +05:30
Kovid Goyal
53c8485a7a Get env conf working with tests 2022-03-03 21:24:44 +05:30
Kovid Goyal
ad91f5af53 ... 2022-03-03 21:24:44 +05:30
pagedown
dc61adf9d8 Refactor: More f-string 2022-01-28 19:34:13 +08:00
Kovid Goyal
6a2522452f Allow including config files matching glob patterns in conf files
Fixes #4533
2022-01-18 16:28:19 +05:30
Kovid Goyal
1454af2d41 macOS: Allow customizing the launch actions 2022-01-07 18:43:07 +05:30
Kovid Goyal
a97a05b1ec Allow action_alias to work with any action 2021-11-23 14:43:36 +05:30
Kovid Goyal
9161c71b51 Show the user an error message when pressing a key results in an exception 2021-11-22 23:01:44 +05:30
Kovid Goyal
2443dc135c Use a faster implementation of the Color type
Now implemented in C
2021-10-28 11:15:13 +05:30
Kovid Goyal
a26f041964 Add more type annotations 2021-10-27 12:31:10 +05:30
Kovid Goyal
6546c1da9b run pyupgrade to upgrade the codebase to python3.6 2021-10-21 12:43:55 +05:30
Kovid Goyal
86a8b231f4 ... 2021-07-04 07:15:15 +05:30
Kovid Goyal
331675d413 Fix ResourceWarning 2021-06-28 20:40:10 +05:30
Kovid Goyal
a1b87f445b Store the paths from which config data is read on the created options object 2021-06-05 12:55:00 +05:30
Kovid Goyal
6d7df1c5e8 Refactor configuration file parsing
Now the time for importing the kitty.config module has been halved, from
16ms from 32ms on my machine. Also, the new architecture will eventually
allow for auto generating a bunch of python-to-C boilerplate code.
2021-05-31 17:40:49 +05:30
Kovid Goyal
49c4b20113 Report bad choice values when parsing config 2021-05-31 17:40:48 +05:30
Kovid Goyal
fe94f4cbb4 Move type parsers for config into own module 2021-05-24 22:29:28 +05:30
Kovid Goyal
3b1d534f6d The parser doesnt need the full defaults object 2021-05-24 14:01:50 +05:30
Kovid Goyal
c1777b1098 DRYer 2021-05-24 13:42:51 +05:30
Kovid Goyal
32f6f18527 DRYer 2021-05-23 11:22:29 +05:30
Kovid Goyal
9114bda24c Get the new bypy based freezing process working with linux builds 2021-02-17 15:50:53 +05:30
Kovid Goyal
9cf5348c36 Modify ImageMagick wrapper to handle animated images 2021-02-01 14:12:26 +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
be1ff61e4a Improve some utility functions
Make expandvars accept both $VARNAME and ${VARNAME} now matches
the behavior of posixpath.expandvars

Allow overriding the environment variables to_cmdline expands against
2020-09-18 13:25:59 +05:30
Kovid Goyal
c92aca5d19 Use a Literal as the type for choice based options 2020-04-24 19:45:51 +05:30
Kovid Goyal
5f06d3a427 Disallow untyped decorators 2020-03-14 14:50:04 +05:30
Kovid Goyal
2ebdf738ca more typing work 2020-03-11 20:08:16 +05:30
Kovid Goyal
8ae110691e More typing work 2020-03-09 21:06:13 +05:30
Kovid Goyal
308d171dae More typing work 2020-03-08 18:55:30 +05:30