Crates.io | mashin_sdk |
lib.rs | mashin_sdk |
version | 0.1.11 |
source | src |
created_at | 2023-04-06 20:21:25.939424 |
updated_at | 2023-05-03 18:08:28.338103 |
description | SDK for writing mashin resources |
homepage | |
repository | https://github.com/nutshimit/mashin |
max_upload_size | |
id | 832460 |
size | 42,309 |
The Mashin SDK is a Rust library for creating custom providers and resources that can be used with the Mashin engine. It provides a set of traits and macros that simplify the process of developing new providers and resources, making it easy for developers to extend the functionality of Mashin.
Provider
and Resource
traits for implementing custom providers and resourcesconstruct_provider!
and resource
macros for simplifying provider and resource creationProviderState
for managing provider state dataResourceResult
for handling serialized resource stateCliLogger
for easy provider and resource loggingTo get started with the Mashin SDK, add it as a dependency to your Cargo.toml:
[dependencies]
mashin_sdk = "0.1"
Then, you can start building your custom provider or resource by implementing the appropriate traits and using the provided macros.
Here's a simple example of how to create a custom provider and resource using the Mashin SDK:
/// Construct the provider and register resources
mashin_sdk::construct_provider!(
my_provider,
config = {},
resources = [my_resource],
);
/// Create a resource
#[mashin_sdk::resource]
pub mod my_resource {
#[mashin::config]
pub struct Config {}
#[mashin::resource]
pub struct Resource {}
#[mashin::calls]
impl mashin_sdk::Resource for Resource {}
}
For more information on how to use the Mashin SDK see the documentation.
Nutshimit is an innovative software company specializing in Infrastructure as Code (IaC) solutions. Our flagship product, Mashin, empowers developers to streamline infrastructure management with a secure, user-friendly, and efficient scripting engine. Built on top of Deno and Rust, Mashin combines the power of TypeScript with the flexibility and safety of a sandboxed environment.
Join us as we revolutionize the way developers create and manage cloud infrastructure.