Mitchell Hashimoto
66143a33ef
input: move flags to a packed struct
2024-09-23 14:03:53 -07:00
Mitchell Hashimoto
a389987ada
cli: config structure supports tagged unions
...
The syntax of tagged unions is `tag:value`. This matches the tagged
union parsing syntax for keybindings (i.e. `new_split:right`).
I'm adding this now on its own without a user-facing feature because
I can see some places we might use this and I want to separate this out.
There is already a PR open now that can utilize this (#2231 ).
2024-09-16 15:53:59 -07:00
Mitchell Hashimoto
11c3ca69f5
cli/crash-report: make it simpler (uglier, honestly)
2024-09-10 21:15:40 -07:00
Jeffrey C. Ollie
6292cdec0e
remove unnecessary imports
2024-09-10 20:43:00 -07:00
Jeffrey C. Ollie
d907cebae9
feat: basic +crash-report cli action
...
Only lists crash reports right now. Viewing and/or submitting crash
reports to come later.
2024-09-10 20:43:00 -07:00
xdBronch
b748ae6c0f
make +version hyperlink to the github commit
2024-09-02 18:48:49 -07:00
Mitchell Hashimoto
f1aea10a84
cli/version: don't parse any args
...
Fixes #2166
2024-08-31 10:39:22 -07:00
Mitchell Hashimoto
7dfad49e40
input: converting set entries to Entry from Action
2024-08-18 20:30:32 -07:00
Jeffrey C. Ollie
7de692c955
themes: don't use arena directly and cleanup debug code
2024-08-18 19:20:42 -07:00
Jeffrey C. Ollie
8c4cfc3bbb
themes: finish refactor
2024-08-18 19:20:42 -07:00
Jeffrey C. Ollie
87791ed562
themes: add a switch that shows a small preview of each theme
2024-08-18 19:20:42 -07:00
Jeffrey C. Ollie
7a11b22c5f
themes: allow loading from absolute paths and from user config dir
2024-08-18 19:20:42 -07:00
Mitchell Hashimoto
b65a804bb2
almost yeeted it all!
2024-08-16 14:42:32 -07:00
Mitchell Hashimoto
aee6857021
cli/list-keybinds: fix windows build
2024-08-06 15:03:38 -07:00
Mitchell Hashimoto
64c267a8c7
Merge pull request #2052 from rockorager/pretty-print
...
cli/list-keybinds: add pretty printing
2024-08-06 14:53:15 -07:00
Mitchell Hashimoto
d00ab8130a
cli: note --plain
2024-08-06 14:53:00 -07:00
karei
85f19bcd12
cli/list-keybinds: align actions at the same column
2024-08-06 14:16:17 -05:00
Tim Culverhouse
8b834c1588
cli/list-keybinds: set default winsize for windows
...
When on windows, set some default terminal size. The actual size is not
very important to our use case here, but we do need one
2024-08-06 13:41:41 -05:00
Tim Culverhouse
e2a59ba77c
cli/list-keybinds: set vaxis measurement state
2024-08-06 13:39:20 -05:00
Tim Culverhouse
b0ac75d5bc
cli/list-keybinds: restore terminal after exit
...
Deinit the tty and vaxis to restore the terminal upon exiting the
command
2024-08-06 13:28:25 -05:00
Tim Culverhouse
1e91efbbe5
cli/list-keybinds: prevent ios, tvos, and watchos from pretty printing
...
These oses don't supply a tty layer, which prevents us from using the
libvaxis tty. Eventually we can add in using stdout as a writer. For
now, we just don't pretty print there.
2024-08-06 12:40:36 -05:00
Tim Culverhouse
59e226154c
cli/list-keybinds: add pretty printing
...
Add pretty printing to the +list-keybinds command. This is done by
bringing in a dependency on libvaxis to handle the styling. Pretty
printing happens automatically when printing to a tty, and can be
disabled either by redirecting output or using the flag `--plain`
2024-08-06 12:19:39 -05:00
Łukasz Niemier
f9be02a20f
chore: clean up typos
2024-08-05 13:56:57 +02:00
Mitchell Hashimoto
c5d03bbbd6
comment
2024-08-01 20:12:22 -07:00
Jeffrey C. Ollie
c5e9913def
Add +list-actions CLI action to list keybind actions.
2024-08-01 18:57:37 -05:00
Mitchell Hashimoto
b3e1b2e02a
some tweaks
2024-07-22 09:48:23 -07:00
Remi Gelinas
699fce0ee5
docs: add docstrings
2024-07-18 11:03:23 -04:00
Remi Gelinas
0197f6d15e
fix: handle recursive config files
2024-07-17 17:27:31 -04:00
Remi Gelinas
a546da0417
feat: print every config error message
2024-07-17 17:03:09 -04:00
Remi Gelinas
368868f712
fix: handle relative paths in CLI
2024-07-17 16:51:16 -04:00
Remi Gelinas
3350e3c848
refactor: move config file loading into loadFile
2024-07-17 15:02:03 -04:00
Remi Gelinas
431c99313c
feat(cli): add initial validate-config action
2024-07-17 12:27:12 -04:00
Jon Parise
9de940cbbf
cli: boolean value support for packed structs
...
Allow standalone boolean values like "true" and "false" to turn on or
off all of the struct's fields.
2024-07-09 09:08:27 -04:00
Gordon Cassie
c967a35abb
Fix some basic build errors.
2024-06-24 15:16:24 -07:00
Qwerasd
d4a7549222
feat(font): Non-integer point sizes
...
Allows for high dpi displays to get odd numbered pixel sizes, for
example, 13.5pt @ 2px/pt for 27px font. This implementation performs
all the sizing calculations with f32, rounding to the nearest pixel
size when it comes to rendering. In the future this can be enhanced
by adding fractional scaling to support fractional pixel sizes.
2024-05-09 00:03:40 -04:00
Mitchell Hashimoto
0c888af470
cli: arg parsing supports more int types
2024-03-22 20:27:31 -07:00
Mitchell Hashimoto
b48d24a546
update zig
2024-03-13 09:14:12 -07:00
Mitchell Hashimoto
26c7215cf8
forgot commit to get #1363 building to new API
2024-01-26 09:04:32 -08:00
Mitchell Hashimoto
d50307c219
Merge pull request #1363 from jcollie/list-keybinds-docs
...
Add option to include docs when listing keybinds.
2024-01-26 09:02:49 -08:00
Mitchell Hashimoto
0f133ae4a7
config: re-expand relative paths correctly when reloading config
...
Fixes #1366
When we use `loadTheme`, we "replay" the configuration so that the theme
is the base configuration and everything else can override everything
the theme sets. During this process, we were not properly re-expanding
all the relative paths.
This fix works by changing our input tracking from solely tracking args
to tracking operations such as expansion as well. When we "replay" the
configuration we also replay operations such as path expansion with the
correct base path.
This also removes the `_inputs` special mechanism `cli/args.zig` had
because we can already do that ourselves using `parseManuallyHook`.
2024-01-23 21:59:34 -08:00
Mitchell Hashimoto
c9371500c9
empty cli or config args reset the value to the default
...
Fixes #1367
We previously special-cased optionals but we should do better and have
this reset ANY type to the defined default value on the struct.
2024-01-23 18:57:33 -08:00
Jeffrey C. Ollie
d51b6d4799
Add option to include docs when listing keybinds.
2024-01-23 00:26:38 -06:00
Mitchell Hashimoto
3176ef86d9
cli: remove list-keybinds changes
2024-01-21 20:50:18 -08:00
Jeffrey C. Ollie
f41f70c977
Use keybind actions help strings in +list-keybinds.
2024-01-21 19:48:48 -06:00
Jeffrey C. Ollie
510f270c54
markdown-ify help strings
2024-01-21 15:07:37 -06:00
Mitchell Hashimoto
27453b64e6
cli/show-config: enable --help
2024-01-20 19:44:54 -08:00
Mitchell Hashimoto
ddd17eda06
cli: list-keybinds uses new config formatting API
2024-01-20 19:39:47 -08:00
Jeffrey C. Ollie
863c3933d3
use keybind struct's built-in capabity to format itself in +list-keybinds action
2024-01-20 19:38:12 -08:00
Mitchell Hashimoto
73a30ccd82
cli/show-config: add the changes-only and docs options
2024-01-20 19:37:48 -08:00
Jeffrey C. Ollie
de428d9fe9
add +show-config action to print out the config from the cli
2024-01-20 19:24:17 -08:00