This is an automated archive made by the Lemmit Bot.
The original was posted on /r/rust by /u/Mediocre-Control-279 on 2024-11-03 17:44:16+00:00.
I wrote a rust tool which takes a few files as input and gives an output file. It is pure rust with no external dependencies. It is not interactive, it’s really just cargo run file1 file2 file3 output
when I use it.
I want my colleagues to be able to use it, but anything involving a command line will not be acceptable. So I thought I’d try to pack it as wasm: Have a super simple web page that allows the user to upload the necessary input files into memory that is accessible to the wasm application, click on “Do the thing!”, have the rust application do its thing and then download the result. I am not looking for pretty or reactive or whatever. I am looking to bundle a command line tool in a way that my colleagues can begrudgingly use it and which causes me the least amount of pain possible.
As I understand it, this should be entirely possible and I’m completely fine to read the documentation and figure things out, but I’m unsure where to start. I would like to avoid big libraries (and definitely anything related to npm). I would like to avoid anything JS related as much as possible, as I have very little experience and next to no motivation to learn. I also have no interest in doing this in a proper client/server fashion: the computations (which are somewhat expensive) need to happen on the user’s device.
I’m finding a lot of projects which seem to be waaaaay overkill for my use case and introducing a lot of overhead for me. I also find a lot of info from around six years ago, which I fear might be outdated. Any hints for directions I should consider would be very much appreciated.