Skip to content

Commit

Permalink
added function to color flag and removed 32-bit seeds **for now**
Browse files Browse the repository at this point in the history
  • Loading branch information
lnxwizard committed Oct 6, 2023
1 parent 05e98ae commit e8e5fed
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,22 @@ mod cli;

use clap::Parser;
use cli::Cli;
use colored::Colorize;
use rand::random;

fn main() {
let _cli = Cli::parse();
fn main() -> Result<(), ()> {
// parse arguments
let cli = Cli::parse();

// generate random 64-bit signed integers
let seed64: i64 = random();
let seed32: i32 = random();

println!("64-bit Seed: {}", seed64);
println!("32-bit Seed: {}", seed32);
if !cli.color {
println!("{}: {}", "64-bit Seed".bold().green(), seed64);
return Ok(());
}

println!("{}: {}", "64-bit Seed", seed64);

Ok(())
}

0 comments on commit e8e5fed

Please sign in to comment.