Skip to the content.

使用 codex 重写 collei

why 要重写

bash vs python

和 python 做对比:

为什么最开始我会不喜欢 python ?

python 的好处:

bash 的问题

how

好处

似乎有一些问题一直很难解决:

vm_dir 的生命周期:

s / t : 虚拟机

长期无法完成的工作用 python 实现起来很容易

无法测试

问题

  1. 莫名其妙的抽象:
    class ActionContext:
     collei: ColleiContext
     vm: VmRuntime
     runner: CommandRunner
     auto_yes: bool = False
    
     def ssh_info(self) -> tuple[str, str, int | None]:
         user = self.vm.config.options.get("user") or "root"
         ip = self.vm.config.options.get("ip")
         if ip is not None:
             return user, ip, None
         return user, "localhost", self.vm.tcp_port("ssh")
    

其他内容

https://bun.com/blog/bun-in-rust

如果真的如此,那么说 gpt 5.5 和 claude fable 的差别就太大了。

https://andrewkelley.me/post/my-thoughts-bun-rust-rewrite.html

TODO

  1. 似乎存在太多 context.vm.directory / context.vm.which_qemu

本站所有文章转发 CSDN 将按侵权追究法律责任,其它情况随意。