Crates.io | usask_cba_calc |
lib.rs | usask_cba_calc |
version | 0.4.2 |
source | src |
created_at | 2023-10-20 09:53:22.133164 |
updated_at | 2023-11-04 02:40:03.796799 |
description | cli tool to calculate usask's first year engineering cba grades |
homepage | |
repository | https://github.com/frroossst/usask_cba_calc |
max_upload_size | |
id | 1008850 |
size | 33,764 |
A command-line tool designed to calculate the first-year engineering grades for students at the University of Saskatchewan's College of Engineering. This tool takes an input file in JSON format and provides the calculated GPA and other relevant information. The tool is written in Rust to take advantage of Rust's excellent data modelling capabilities.
Install Rust: If you don't already have Rust installed on your system, you can do so by visiting the official Rust website and following their installation instructions.
Install the Binary: Use cargo to install the binary from crates.io
cargo install usask_cba_calculator
Verify Installation: Run the following command in your terminal
usask_cba_calc --help
The output should look something like this,
Usage: usask-cba-calc [file_path]
Arguments:
[file_path] Path to file containing JSON data.
If no file path is provided, the program will read from stdin.
cli tool to calculate usask's first year engineering cba grades
usask-cba-calc v0.2.3
Open up your terminal or command prompt
Type usask_cba_calc -s
This will ask you a few questions to generate a boiler plate JSON schema, later open the grades.json file to fill in your grade information
Type usask_cba_calc /path/to/file.json
NOTE: You can also pipe in data to the tool.
The way the input file needs to be structured is very specific, follow the general layout shown below
{
"Subject1": {
"CLOs": {
"1.1": {
"difficulty_type": "B",
"weightage": 20.0,
"RLOs": {
"1.3": {
"weightage": 50.0,
"assignments": [95, 90, 85]
},
"3.3": {
"weightage": 50.0,
"assignments": [80, 75]
}
}
},
"1.2": {
"difficulty_type": "B+",
"weightage": 80.0,
"RLOs": {
"1.1": {
"weightage": 50.0,
"assignments": [95, 90, 85]
}
}
}
}
},
"Subject2": {
"CLOs": {
"2.1": {
"difficulty_type": "A",
"weightage": 0.0,
"RLOs": {
"2.1": {
"weightage": 100.0,
"assignments": [12]
}
}
},
"1.2": {
"difficulty_type": "B+",
"weightage": 100.0,
"RLOs": {
"2.2": {
"weightage": 100.0,
"assignments": [95, 0, 0]
}
}
}
}
}
}