GabrielJuan349 / Rust-template

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

My Rust Project

This project serves as a template to kickstart your Rust application development.

Table of Contents

Prerequisites

  • Ensure Rust is installed on your machine. If not, you can install it using rustup.

Setup

Create a New Project

To create a new Rust project, run:

cargo new my_project
cd my_project

Project Structure

Here's a brief overview of the project's structure:

.
├── src
│   ├── main.rs
├── Cargo.toml
├── .gitignore
└── README.md

  • src/main.rs: The main source file where the execution starts.
  • Cargo.toml: The configuration file for Rust's package manager, Cargo.

Example Code

Add the following code to src/main.rs:

fn main() {
    println!("Hello, Rust!");
}

Building and Running

To build and run the project:

cargo build
cargo run

Contributing

Contributions are welcome! Please follow the standard code of conduct and submit pull requests or open issues as needed.

License

This project is licensed under the Mozilla Public License Version 2.0. See the LICENSE file for more details.

This README.md focuses on the essential steps to initiate a Rust project, omitting detailed explanations about Rust itself.

About

License:Mozilla Public License 2.0


Languages

Language:Rust 100.0%