Add structured rtk dotnet support (build/test/restore) with binlog/TRX parsing, robust argument forwarding, and locale-stable fallback behavior#172
Conversation
|
@DavidFowler this might be something of interest to you It probably still misses a few things but might be a good start |
|
Will be testing this during the week. Thanks for enormous work. |
|
This is an outstanding PR — probably the most thorough community contribution we've received. The binary binlog parser, multi-layer fallback strategy (binlog → text → TRX), and 42 tests A few things to address before merge:
Without this, Claude Code will type dotnet build and it won't go through the RTK filter. Every command we support has a corresponding rewrite in .claude/hooks/rtk-rewrite.sh. Please add: --- .NET ---elif echo "$MATCH_CMD" | grep -qE '^dotnet[[:space:]]+(build|test|restore)([[:space:]]|$)'; then See the cargo/pytest/ruff sections in the hook file for examples.
In dotnet_cmd.rs, run_dotnet_with_binlog() for "build" does:
This function calls Regex::new() in a loop for every env var on every invocation. Should be lazy_static! to avoid recompilation. Not a blocker but matters for performance.
build_binlog_path() creates files in /tmp/rtk_dotnet_* but never removes them. Could accumulate over time. Consider cleaning up after parsing, similar to how you handle TRX cleanup. None of these are major — #1 is the only blocker. Great work! |
|
Thank you for the kinds words It will take a while until I can address those because I have a few prio things I need to get through first but I should be able to get back to this next week |
|
Thank you Dani :) Looking forward to try this out. |
|
I think I addressed the feedback plus some additional robustness things I stumbled upon while doing more testing. I've also added Format support |
Why
Benefits
Real-world impact (NServiceBus)
Solution-level run against NServiceBus.slnx:
More outputs