Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mpwsh/filepush-rs
Simple library to upload and download files to/from https://filepush.co/ using Rust
https://github.com/mpwsh/filepush-rs
Last synced: 10 days ago
JSON representation
Simple library to upload and download files to/from https://filepush.co/ using Rust
- Host: GitHub
- URL: https://github.com/mpwsh/filepush-rs
- Owner: mpwsh
- Created: 2019-10-16T05:04:41.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2019-10-19T19:43:13.000Z (about 5 years ago)
- Last Synced: 2024-10-31T11:44:45.504Z (17 days ago)
- Language: Rust
- Homepage: https://crates.io/crates/filepush-rs
- Size: 10.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# filepush-rs
Small Rust library to upload and download files from/to [filepush.co](https://filepush.co).
I forked the [transfer-rs](https://crates.io/crates/transfer-rs) library and added download capabilities.
## Usage
```rust
extern crate filepush;
use filepush::{upload, download};fn main() {
match upload("Cargo.toml") {
Ok(url) => println!("{}", url),
Err(err) => panic!("Error: {}", err),
};
match download("https://filepush.co/9LY9/test1") {
Ok(url) => println!("{}", url),
Err(err) => panic!("Error: {}", err),
};
}
```A simple CLI application is provided in the [examples](examples/) directory.
## Building
- Install rustc using [RustUp](https://rustup.rs)
- Run `cargo build --release`## Cli app usage from examples folder
- `git clone https://github.com/marianopw/filepush-rs`
- `cd filepush-rs`
- `cargo run --example cli_client -- -u yourfile`
- `cargo run --example cli_client -- -d yourlink`## Credit
Transfer-rs lib author is [Harsh Shandilya](https://github.com/msfjarvis)