nelsonjchen / speedtest-rs

(Unmaintained) speedtest-cli in Rust.
Apache License 2.0
164 stars 17 forks source link

JSON support #9

Open Hellseher opened 6 years ago

Hellseher commented 6 years ago

Hi,

Thank you for your work, just feature suggestion for JSON support like speedtest-cli.py has.

I've recently started dig into Rust and want to combine it with my Ansible (ansible_local.speedtest) for speed tests on remote servers.

nelsonjchen commented 6 years ago

There's JSON support in the original?! Wow, I haven't kept up with that in some time.

nelsonjchen commented 6 years ago

Yikes, I took some time this weekend to sit down and take a look at the features. They've really added a ton of features to speedtest-cli.py since I last really worked on this tool about 2 years ago.

nelsonjchen commented 6 years ago

I'll try to get to this once I get this project up to something to like Rust-2018 standards.

asukaminato0721 commented 11 months ago

I notice that here is a branch https://github.com/nelsonjchen/speedtest-rs/tree/json

I'll try to get to this once I get this project up to something to like Rust-2018 standards.

finished.


It seems that if use the simplest way, then serde_json::to_string(&result)? can do it.


Before I find that json branch, I made this simple fork:

https://github.com/asukaminato0721/speedtest-rs/tree/json

it can ./speedtest-rs --json