Rust: Difference between revisions

From Braindump
Jump to navigation Jump to search
No edit summary
 
No edit summary
 
Line 1: Line 1:
cargo
cargo
  curl -sSf https://sh.rustup.rs | sh
  curl -sSf https://sh.rustup.rs | sh
<code>rustc hello.rs</code>
<code>cargo new foo</code>
<code>cargo new --lib bar</code>
<code>Cargo.toml</code>
<code>[package]</code>
<code>name = "foo"</code>
<code>version = "0.1.0"</code>
<code>authors = ["mark"]</code>
<code>[dependencies]</code>
https://doc.rust-lang.org/rust-by-example/hello.html

Latest revision as of 13:57, 12 December 2025

cargo

curl -sSf https://sh.rustup.rs | sh

rustc hello.rs

cargo new foo

cargo new --lib bar


Cargo.toml

[package]

name = "foo"

version = "0.1.0"

authors = ["mark"]

[dependencies]

https://doc.rust-lang.org/rust-by-example/hello.html