Out of sheer curiosity, I'm using the following line to upload files to a Sinatra app:
curl -silent --location --upload-file #{file} http://0.0.0.0:3000/sent/
It works like charm. However if I want to use a pure ruby solution like HTTPClient, what would be the code to get the same result? Can you give me an example?
NOTE: I'm not interested in libcurl related solutions. If there's another gem, except HTTPClient that can achieve this in pure ruby please share.
Best Regards