Project Title
A Rust package to learn Rust and use/install npm packages.
Getting Started
let npm = Package::new("npm", Some("npm"));
let install_package = |package: &package_js::Package| -> Result<()> {
match package.installed() {
Ok(_) => {
println!("Package {} allready installed", &package.name);
Ok(())
}
Err(_) => {
println!("Package {} not installed, installing now", &package.name);
package.install().expect("Could not install pacakge");
Ok(())
}
}
};
install_package(&package_js::Package::new("typescript", None))?;
let buidler = Package::new("@nomiclabs/buidler", Some("buidler"));
assert!(buidler.installed().is_ok());
Built With
Contributing
Versioning
Authors
- Robertosnap - Initial work - Robertosnap
See also the list of contributors who participated in this project.
License
This project is licensed under the MIT License - see the LICENSE.md file for details
Acknowledgments
- Hat tip to anyone whose code was used