fix error link for json config and also add space at end of each error
This commit is contained in:
parent
69c00af53c
commit
3383bb8434
2 changed files with 14 additions and 10 deletions
10
README.md
10
README.md
|
@ -1,9 +1,13 @@
|
||||||
# idmangler-cli
|
# idmangler-cli
|
||||||
yeah basically this generates fake items by loading from a json. Effectively a wrapper for [zatzou's idmangler-lib](https://github.com/Zatzou/idmangler-lib).
|
Basically this generates fake items by loading from a json. Effectively a wrapper for [zatzou's idmangler-lib](https://github.com/Zatzou/idmangler-lib).
|
||||||
|
|
||||||
how to use:
|
## How to get the program
|
||||||
|
### Option 1: prebuilt
|
||||||
|
Go to the releases tab
|
||||||
|
|
||||||
|
## how to use:
|
||||||
|
|
||||||
requirements: rust, cargo
|
requirements: rust, cargo
|
||||||
use cargo run --release to build and run
|
use cargo run --release to build and run
|
||||||
|
|
||||||
read the provided config markdown file to understand how to edit values.json
|
read the provided config markdown file to understand how to edit config.json
|
||||||
|
|
14
src/main.rs
14
src/main.rs
|
@ -62,7 +62,7 @@ fn main() {
|
||||||
|
|
||||||
// newest json reading code
|
// newest json reading code
|
||||||
let json_config: jsonconfig = serde_json::from_reader(
|
let json_config: jsonconfig = serde_json::from_reader(
|
||||||
fs::File::open("../config.json").expect(ERROR[1]))
|
fs::File::open("config.json").expect(ERROR[1]))
|
||||||
.expect(ERROR[2]);
|
.expect(ERROR[2]);
|
||||||
let idsmap: HashMap<String, u8> = serde_json::from_reader(
|
let idsmap: HashMap<String, u8> = serde_json::from_reader(
|
||||||
fs::File::open("id_keys.json").expect(ERROR[3]))
|
fs::File::open("id_keys.json").expect(ERROR[3]))
|
||||||
|
@ -258,12 +258,12 @@ fn pass() {
|
||||||
|
|
||||||
const ERROR: [&'static str; 7] = [
|
const ERROR: [&'static str; 7] = [
|
||||||
"Error 0: what did you even do to get this? ",
|
"Error 0: what did you even do to get this? ",
|
||||||
"Error 1: json config file is missing, reobtain it from the config.json I have sent you. ",
|
"Error 1: json config file is missing, obtain it from https://git.frfrnocap.men/endernon/idmangler-cli/raw/branch/main/config.json and move it to this directory. ",
|
||||||
"Error 2: json config is broken. Reread the example data or get it from ",
|
"Error 2: json config is broken. Reread the example data or reobtain it from https://git.frfrnocap.men/endernon/idmangler-cli/raw/branch/main/config.json and move it to this diirectory. ",
|
||||||
"Error 3: Identifications hashmap not found. Get it from https://raw.githubusercontent.com/Wynntils/Static-Storage/main/Reference/id_keys.json and move it to this directory.",
|
"Error 3: Identifications hashmap not found. Get it from https://raw.githubusercontent.com/Wynntils/Static-Storage/main/Reference/id_keys.json and move it to this directory. ",
|
||||||
"Error 4: Identifications hashhmap is corrupt. Reobtain it from https://raw.githubusercontent.com/Wynntils/Static-Storage/main/Reference/id_keys.json and move it to this directory.",
|
"Error 4: Identifications hashhmap is corrupt. Reobtain it from https://raw.githubusercontent.com/Wynntils/Static-Storage/main/Reference/id_keys.json and move it to this directory. ",
|
||||||
"Error 5: Shiny data json is missing. Get it from https://raw.githubusercontent.com/Wynntils/Static-Storage/a8469fad2f3bd0fc0fe2678eeb812d7877c9e61b/Data-Storage/shiny_stats.json",
|
"Error 5: Shiny data json is missing. Get it from https://raw.githubusercontent.com/Wynntils/Static-Storage/a8469fad2f3bd0fc0fe2678eeb812d7877c9e61b/Data-Storage/shiny_stats.json and move it to this directory. ",
|
||||||
"Error 6: Shiny data json is corrupt. Get it from https://raw.githubusercontent.com/Wynntils/Static-Storage/a8469fad2f3bd0fc0fe2678eeb812d7877c9e61b/Data-Storage/shiny_stats.json"
|
"Error 6: Shiny data json is corrupt. Get it from https://raw.githubusercontent.com/Wynntils/Static-Storage/a8469fad2f3bd0fc0fe2678eeb812d7877c9e61b/Data-Storage/shiny_stats.json and move it to this directory. "
|
||||||
];
|
];
|
||||||
const _BOIL: [&'static str; 3] = [
|
const _BOIL: [&'static str; 3] = [
|
||||||
"0",
|
"0",
|
||||||
|
|
Loading…
Reference in a new issue