Skip to content

Commit 21d74fe

Browse files
committed
Initial commi
0 parents  commit 21d74fe

1,339 files changed

Lines changed: 49117 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/ci.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [ main, master ]
6+
pull_request:
7+
branches: [ main, master ]
8+
9+
jobs:
10+
test:
11+
name: Test
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
- name: Install Rust
18+
uses: dtolnay/rust-toolchain@stable
19+
with:
20+
components: rustfmt, clippy
21+
22+
- name: Cache Cargo
23+
uses: actions/cache@v3
24+
with:
25+
path: |
26+
~/.cargo/bin/
27+
~/.cargo/registry/index/
28+
~/.cargo/registry/cache/
29+
~/.cargo/git/db/
30+
target/
31+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
32+
33+
- name: Build
34+
run: cargo build --workspace
35+
36+
- name: Run tests
37+
run: cargo test --workspace
38+
39+
- name: Run clippy
40+
run: cargo clippy --workspace -- -D warnings
41+
42+
- name: Check formatting
43+
run: cargo fmt --all -- --check
44+
45+
- name: Audit dependencies
46+
uses: rustsec/rustsec-action@master
47+
with:
48+
args: --deny warnings
49+
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Test All Examples
2+
3+
on:
4+
push:
5+
branches: [ main, master ]
6+
pull_request:
7+
branches: [ main, master ]
8+
9+
jobs:
10+
test:
11+
name: Test on ${{ matrix.toolchain }}
12+
runs-on: ubuntu-latest
13+
14+
strategy:
15+
matrix:
16+
toolchain: [stable, beta, nightly]
17+
18+
steps:
19+
- uses: actions/checkout@v4
20+
21+
- name: Install Rust ${{ matrix.toolchain }}
22+
uses: dtolnay/rust-toolchain@master
23+
with:
24+
toolchain: ${{ matrix.toolchain }}
25+
26+
- name: Cache Cargo
27+
uses: actions/cache@v3
28+
with:
29+
path: |
30+
~/.cargo/bin/
31+
~/.cargo/registry/index/
32+
~/.cargo/registry/cache/
33+
~/.cargo/git/db/
34+
target/
35+
key: ${{ runner.os }}-cargo-${{ matrix.toolchain }}-${{ hashFiles('**/Cargo.lock') }}
36+
37+
- name: Build all projects
38+
run: cargo build --workspace --release
39+
40+
- name: Run all tests
41+
run: cargo test --workspace --release
42+
continue-on-error: ${{ matrix.toolchain == 'nightly' }}
43+

.gitignore

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
# Rust
2+
target/
3+
Cargo.lock
4+
**/*.rs.bk
5+
*.pdb
6+
7+
# ide
8+
.vscode/
9+
.idea/
10+
*.swp
11+
*.swo
12+
*~
13+
.cursor/
14+
.cursorrules
15+
16+
# os
17+
.DS_Store
18+
Thumbs.db
19+
*.swp
20+
*.swo
21+
*~
22+
23+
# documentation (duplicated)
24+
book/book/
25+
26+
# tests
27+
*.orig
28+
29+
# sensitive files
30+
.env
31+
.env.local
32+
.env.*.local
33+
*.key
34+
*.pem
35+
*.p12
36+
secrets/
37+
*.secret
38+
39+
# temporary files
40+
*.log
41+
*.tmp
42+
*.temp
43+
*.cache
44+
__pycache__/
45+
*.pyc
46+
*.pyo
47+
*.pyd
48+
.Python
49+
50+
# build files
51+
dist/
52+
build/
53+
*.egg-info/
54+
.eggs/
55+
56+
# Node modules
57+
node_modules/
58+
npm-debug.log*
59+
yarn-debug.log*
60+
yarn-error.log*
61+
62+
# system files
63+
*.bak
64+
*.backup
65+
*~
66+
.#*
67+
68+
# editor
69+
*.sublime-project
70+
*.sublime-workspace
71+
.project
72+
.classpath
73+
.settings/
74+
75+
# coverage
76+
coverage/
77+
*.gcov
78+
*.gcda
79+
*.gcno
80+
81+
# profiling
82+
*.prof
83+
perf.data*
84+
flamegraph.svg

Cargo.toml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
[workspace]
2+
members = [
3+
"projects/p01-hello-world",
4+
"projects/p02-cli-calculator",
5+
"projects/p03-mini-http-server",
6+
"projects/p04-data-pipeline",
7+
"projects/p05-terminal-game",
8+
"projects/p06-web-service",
9+
]
10+
11+
[workspace.package]
12+
version = "1.0.0"
13+
edition = "2021"
14+
authors = ["Rust Learning Guide - AnonSecLab"]
15+
license = "PROPRIETARY"
16+
17+
[workspace.dependencies]
18+
tokio = { version = "1.35", features = ["full"] }
19+
serde = { version = "1.0", features = ["derive"] }
20+
serde_json = "1.0"
21+
anyhow = "1.0"
22+
thiserror = "1.0"
23+
clap = { version = "4.4", features = ["derive"] }
24+
csv = "1.3"
25+
reqwest = { version = "0.11", features = ["json"] }
26+

LICENSE

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
## Licence
2+
3+
**Copyright (c) 2026. All Rights Reserved.**
4+
5+
This work, including but not limited to all text, code examples, exercises, projects, documentation, and associated materials contained in this Rust Learning Guide, is the exclusive property of the copyright holder.
6+
7+
**RESTRICTIONS:**
8+
9+
- **No Reproduction**: This work may not be reproduced, in whole or in part, in any form or by any means, electronic or mechanical, including photocopying, recording, or by any information storage and retrieval system, without prior written permission from the copyright holder.
10+
11+
- **No Distribution**: This work may not be distributed, shared, or made available to third parties, whether for commercial or non-commercial purposes, without explicit written authorization.
12+
13+
- **No Modification**: This work may not be modified, adapted, translated, or used to create derivative works without the express written consent of the copyright holder.
14+
15+
- **No Commercial Use**: This work may not be used for any commercial purpose, including but not limited to training programs, courses, or educational services, without a commercial license agreement.
16+
17+
**DISCLAIMER:**
18+
19+
This work is provided "as is" without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose, and non-infringement. In no event shall the copyright holder be liable for any claim, damages, or other liability arising from the use of this work.
20+
21+
**PERMISSIONS:**
22+
23+
For requests regarding reproduction, distribution, modification, or commercial use, please contact the copyright holder to obtain the necessary written authorization.
24+
25+
**Violation of these terms may result in legal action.**

0 commit comments

Comments
 (0)