Commit Graph

1172 Commits

Author SHA1 Message Date
Michael Bolin
7bd4981950 merge commit for archive created by Sapling 2025-05-14 12:21:17 -07:00
Michael Bolin
dd4fd9edfc feat: add support for commands in the Rust TUI 2025-05-14 12:21:09 -07:00
Michael Bolin
5b20a3930b merge commit for archive created by Sapling 2025-05-14 12:13:09 -07:00
Michael Bolin
0673a56351 feat: add support for commands in the Rust TUI 2025-05-14 12:13:04 -07:00
Michael Bolin
618686141a merge commit for archive created by Sapling 2025-05-14 12:11:26 -07:00
Michael Bolin
42cd07527c feat: add support for commands in the Rust TUI 2025-05-14 12:10:27 -07:00
Michael Bolin
d889960200 merge commit for archive created by Sapling 2025-05-14 11:55:24 -07:00
Michael Bolin
739345d1f6 feat: add support for commands in the Rust TUI 2025-05-14 11:55:19 -07:00
Michael Bolin
06c3847b7c Merge 29d10d55a3 into sapling-pr-archive-bolinfest 2025-05-14 11:44:15 -07:00
Michael Bolin
29d10d55a3 feat: add support for commands in the Rust TUI 2025-05-14 11:43:28 -07:00
Michael Bolin
d48f39caf7 Merge 7c34ec776d into sapling-pr-archive-bolinfest 2025-05-14 10:54:45 -07:00
Michael Bolin
7c34ec776d feat: add mcp subcommand to CLI to run Codex as an MCP server 2025-05-14 10:54:37 -07:00
Michael Bolin
0402aef126 chore: move each view used in BottomPane into its own file (#928)
`BottomPane` was getting a bit unwieldy because it maintained a
`PaneState` enum with three variants and many of its methods had `match`
statements to handle each variant. To replace the enum, this PR:

* Introduces a `trait BottomPaneView` that has two implementations:
`StatusIndicatorView` and `ApprovalModalView`.
* Migrates `PaneState::TextInput` into its own struct, `ChatComposer`,
that does **not** implement `BottomPaneView`.
* Updates `BottomPane` so it has `composer: ChatComposer` and
`active_view: Option<Box<dyn BottomPaneView<'a> + 'a>>`. The idea is
that `active_view` takes priority and is displayed when it is `Some`;
otherwise, `ChatComposer` is displayed.
* While methods of `BottomPane` often have to check whether
`active_view` is present to decide which component to delegate to, the
code is more straightforward than before and introducing new
implementations of `BottomPaneView` should be less painful.

Because we want to retain the `TextArea` owned by `ChatComposer` even
when another view is displayed, to keep the ownership logic simple, it
seemed best to keep `ChatComposer` distinct from `BottomPaneView`.
2025-05-14 10:13:29 -07:00
Michael Bolin
13ec2cd577 Merge f9196813ab into sapling-pr-archive-bolinfest 2025-05-14 10:06:37 -07:00
Michael Bolin
f9196813ab chore: move each view used in BottomPane into its own file 2025-05-14 10:06:20 -07:00
Michael Bolin
399e819c9b fix: increase timeout for test_dev_null_write (#933)
After updating this test in https://github.com/openai/codex/pull/923, I
have been getting some timeouts with this test in CI, so increasing the
timeout to match that of `test_writable_root`:


327cf41f0f/codex-rs/core/src/landlock.rs (L211-L213)
2025-05-14 10:06:14 -07:00
Michael Bolin
9e90befce9 Merge d1d918f09a into sapling-pr-archive-bolinfest 2025-05-14 10:03:39 -07:00
Michael Bolin
d1d918f09a fix: increase timeout for test_dev_null_write 2025-05-14 10:03:32 -07:00
Michael Bolin
7849b06fcf merge commit for archive created by Sapling 2025-05-14 09:56:22 -07:00
Michael Bolin
a961801cd0 chore: move each view used in BottomPane into its own file 2025-05-14 09:56:04 -07:00
Michael Bolin
31c72bc460 Merge 57311cb597 into sapling-pr-archive-bolinfest 2025-05-14 09:40:48 -07:00
Michael Bolin
57311cb597 chore: move each view used in BottomPane into its own file 2025-05-14 09:40:43 -07:00
Yaroslav Halchenko
327cf41f0f Add codespell support (config, workflow to detect/not fix) and make it fix some typos (#903)
More about codespell: https://github.com/codespell-project/codespell .

I personally introduced it to dozens if not hundreds of projects already
and so far only positive feedback.

CI workflow has 'permissions' set only to 'read' so also should be safe.

Let me know if just want to take typo fixes in and get rid of the CI

---------

Signed-off-by: Yaroslav O. Halchenko <debian@onerussian.com>
2025-05-14 09:39:49 -07:00
Michael Bolin
0f92262cc1 merge commit for archive created by Sapling 2025-05-14 09:24:10 -07:00
Michael Bolin
e52d31211f chore: move each view used in BottomPane into its own file 2025-05-14 09:24:02 -07:00
Fouad Matin
9e7cd2b25a bump(version): 0.1.2505140839 (#932)
## `0.1.2505140839`

### 🪲 Bug Fixes

- Gpt-4.1 apply_patch handling (#930)
- Add support for fileOpener in config.json (#911)
- Patch in #366 and #367 for marked-terminal (#916)
- Remember to set lastIndex = 0 on shared RegExp (#918)
- Always load version from package.json at runtime (#909)
- Tweak the label for citations for better rendering (#919)
- Tighten up some logic around session timestamps and ids (#922)
- Change EventMsg enum so every variant takes a single struct (#925)
- Reasoning default to medium, show workdir when supplied (#931)
- Test_dev_null_write() was not using echo as intended (#923)
2025-05-14 08:44:52 -07:00
Fouad Matin
73259351ff fix: reasoning default to medium, show workdir when supplied (#931) 2025-05-14 08:38:41 -07:00
Fouad Matin
77347d268d fix: gpt-4.1 apply_patch handling (#930) 2025-05-14 08:34:09 -07:00
Fouad Matin
678f0dbfec add: dynamic instructions (#927) 2025-05-14 01:27:46 -07:00
Michael Bolin
9c680d438a merge commit for archive created by Sapling 2025-05-13 23:27:07 -07:00
Michael Bolin
603d60f590 chore: move each view used in BottomPane into its own file 2025-05-13 23:27:03 -07:00
Michael Bolin
1801ad556d merge commit for archive created by Sapling 2025-05-13 23:26:26 -07:00
Michael Bolin
118fd6625c chore: move each view used in BottomPane into its own file 2025-05-13 23:26:22 -07:00
Michael Bolin
16cb63bdd3 merge commit for archive created by Sapling 2025-05-13 23:24:08 -07:00
Michael Bolin
1a76d2ad48 chore: move each view used in BottomPane into its own file 2025-05-13 23:24:02 -07:00
Michael Bolin
647d611875 merge commit for archive created by Sapling 2025-05-13 23:23:01 -07:00
Michael Bolin
45140daeb3 chore: move each view used in BottomPane into its own file 2025-05-13 23:22:56 -07:00
Michael Bolin
8ababe50d1 merge commit for archive created by Sapling 2025-05-13 23:19:45 -07:00
Michael Bolin
ae9eb21d50 chore: move each view used in BottomPane into its own file 2025-05-13 23:19:36 -07:00
Michael Bolin
1bf00a3a95 feat: Ctrl+J for newline in Rust TUI, default to one line of height (#926)
While the `TextArea` used in the Rust TUI is "multiline," it is not like
an HTML `<textarea>` in that it does not wrap, so there was not much
benefit to setting `MIN_TEXTAREA_ROWS` to `3`, so this PR changes it to
`1`. Though there are now three ways to "increase" the height due to
actual linebreaks:

* paste in multiline content (this worked before this PR)
* pressing `Ctrl+J` will insert a newline
* if you have your terminal emulator set such that it is possible to
press something that `crossterm` interprets as "Enter plus some
modifier," then now that will also work

Now things look a bit more compact on startup:

<img width="745" alt="image"
src="https://github.com/user-attachments/assets/86e2857f-f31c-46f5-a80b-1ab2120b266e"
/>
2025-05-13 21:42:14 -07:00
Michael Bolin
5bf9445351 fix: test_dev_null_write() was not using echo as intended (#923)
I believe this test meant to verify that echoing content to `/dev/null`
succeeded, but instead, I believe it was testing the equivalent to `echo
'blah > /dev/null'`.
2025-05-13 21:40:26 -07:00
Michael Bolin
e701ae5c22 merge commit for archive created by Sapling 2025-05-13 20:52:44 -07:00
Michael Bolin
fdfdb1a11c feat: Ctrl+J for newline in Rust TUI, default to one line of height 2025-05-13 20:52:39 -07:00
Michael Bolin
341bd57f7c Merge 85c6209e7b into sapling-pr-archive-bolinfest 2025-05-13 20:51:57 -07:00
Michael Bolin
85c6209e7b feat: Ctrl+J for newline in Rust TUI, default to one line of height 2025-05-13 20:51:49 -07:00
Michael Bolin
a5f3a34827 fix: change EventMsg enum so every variant takes a single struct (#925)
https://github.com/openai/codex/pull/922 did this for the
`SessionConfigured` enum variant, and I think it is generally helpful to
be able to work with the values as each enum variant as their own type,
so this converts the remaining variants and updates all of the
callsites.

Added a simple unit test to verify that the JSON-serialized version of
`Event` does not have any unexpected nesting.
2025-05-13 20:44:42 -07:00
Michael Bolin
b5f735f200 merge commit for archive created by Sapling 2025-05-13 20:38:42 -07:00
Michael Bolin
d99bcb9222 fix: change EventMsg enum so every variant takes a single struct 2025-05-13 20:38:37 -07:00
Michael Bolin
05afdeab8e merge commit for archive created by Sapling 2025-05-13 20:36:38 -07:00
Michael Bolin
a017ebffc6 fix: change EventMsg enum so every variant takes a single struct 2025-05-13 20:36:34 -07:00