Skip to content

armlynobinguar/rust-basics-web3-cebu-polkadot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

97 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust Basics for Web3Cebu: Polkadot Workshop

Welcome to the Polkadot Workshop: Intro to Rust for Web3Cebu repository! This repo contains essential resources, documentation, and example scripts to guide you through the basics of Rust, focusing on building in the Web3 ecosystem with Polkadot.

Repository Structure

The repo is organized into the following directories:

  • docs/: Contains comprehensive documentation on Rust topics. These materials will help you understand core Rust concepts relevant to Polkadot development.

  • examples/: Contains practical example scripts demonstrating Rust code. These examples are designed to provide hands-on experience and reinforce the concepts discussed in the docs/ section.

Getting Started

Prerequisites

Before you begin, ensure the following tools are installed on your machine:

  • Rust Toolchain: Install Rust via rustup.
  • Polkadot.js: Install the Polkadot.js API if needed for Polkadot integration.

Cloning the Repository

To clone this repository, use the following command:

git clone https://github.com/yourusername/rust-basics-web3-cebu-polkadot.git

Running the Examples

To run the example scripts, follow these steps:

  1. Navigate to the examples/ directory:

    cd examples/
  2. Use cargo to run the specific example script you want to execute:

    cargo run --example <example-name>

    Replace <example-name> with the name of the example script you'd like to run. For example:

    cargo run --example hello_world
  3. If additional dependencies or packages are required, you will be prompted to install them through cargo. Follow the on-screen instructions to complete installation.

Topics Covered

The workshop covers the following Rust fundamentals:

  • Basic Syntax
  • Variables and Data Types
  • Ownership and Borrowing
  • Functions and Modules
  • Error Handling
  • Traits and Generics
  • Rust for Web3 and Polkadot Development

How to Contribute

We encourage contributions from the community! Here's how you can help:

  1. Fork this repository by clicking the "Fork" button at the top right of this page.

  2. Star the repository if you find it helpful and want to show your support!

  3. Clone your forked version to your local machine:

    git clone https://github.com/your-username/rust-basics-web3-cebu-polkadot.git
  4. Create a new branch for your feature or fix:

    git checkout -b feature-branch-name
  5. Make your changes and commit them:

    git commit -m "Add your commit message here"
  6. Push your changes to your forked repository:

    git push origin feature-branch-name
  7. Submit a pull request (PR) to the original repository for review.

Feel free to open an issue if you find any bugs or have suggestions!

Running Examples after Contribution

After making your contributions, test the example scripts again to ensure your changes work as expected:

  1. Go to the examples/ directory:

    cd examples/
  2. Run the example scripts as before using cargo:

    cargo run --example <example-name>

Make sure your changes do not break any existing examples before submitting your pull request!

License

This project is licensed under the Apache 2.0 License. See the LICENSE file for more details.

Contact

For any questions or feedback, feel free to reach out to us via our community channels or open an issue in the repo.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published