Search lyrics or song metadata from your terminal
genius genius-lyrics-search genius-lyrics cli rust

check GENIUS_TOKEN environment variable

+5 -4
+1 -1
Cargo.lock
··· 286 286 287 287 [[package]] 288 288 name = "genius-cli" 289 - version = "0.1.0" 289 + version = "0.1.1" 290 290 dependencies = [ 291 291 "clap", 292 292 "colored_json",
+1 -1
Cargo.toml
··· 1 1 [package] 2 2 name = "genius-cli" 3 - version = "0.1.0" 3 + version = "0.1.1" 4 4 edition = "2021" 5 5 description = "A command-line interface for Genius.com" 6 6 readme = "README.md"
+3 -2
src/main.rs
··· 1 - use std::env; 1 + use std::{env, process::exit}; 2 2 3 3 use clap::{Arg, Command}; 4 4 use colored_json::ToColoredJson; ··· 54 54 #[tokio::main] 55 55 async fn main() { 56 56 if env::var("GENIUS_TOKEN").unwrap().is_empty() { 57 - panic!("Please set the GENIUS_TOKEN environment variable"); 57 + println!("Please set the GENIUS_TOKEN environment variable"); 58 + exit(1); 58 59 } 59 60 60 61 let genius = Genius::new(env::var("GENIUS_TOKEN").unwrap());