near / near-cli-rs

near CLI is your human-friendly companion that helps to interact with NEAR Protocol from command line.
https://near.cli.rs
Apache License 2.0
105 stars 56 forks source link

Refactor/divide `common.rs` into smaller files #373

Open fadeevab opened 4 months ago

fadeevab commented 4 months ago

Reasons / Why

  1. common.rs is ~2600 lines long, it's pretty huge.
  2. It takes roughly 3 thousand light years 10+ seconds for rust-analyzer to recompile it at every change (Ctrl+S)... on my average laptop.
  3. Another reason for refactoring is the fact that common name is too... common.

I was trying to make a simple patch into common.rs, and clippy recompilation delays made it quite challenging.

Thanks :)

frol commented 3 months ago

@fadeevab common.rs is a pile of ugly hacks that we have to decouple into dedicated crates. We have started to work on it here: https://github.com/akorchyn/near-api