tangled
alpha
login
or
join now
tsiry-sandratraina.com
/
genius-cli
6
fork
atom
Search lyrics or song metadata from your terminal
genius
genius-lyrics-search
genius-lyrics
cli
rust
6
fork
atom
overview
issues
pulls
pipelines
check GENIUS_TOKEN environment variable
tsiry-sandratraina.com
3 years ago
2a7623dc
7eea5695
+5
-4
3 changed files
expand all
collapse all
unified
split
Cargo.lock
Cargo.toml
src
main.rs
+1
-1
Cargo.lock
···
286
286
287
287
[[package]]
288
288
name = "genius-cli"
289
289
-
version = "0.1.0"
289
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
3
-
version = "0.1.0"
3
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
1
-
use std::env;
1
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
57
-
panic!("Please set the GENIUS_TOKEN environment variable");
57
57
+
println!("Please set the GENIUS_TOKEN environment variable");
58
58
+
exit(1);
58
59
}
59
60
60
61
let genius = Genius::new(env::var("GENIUS_TOKEN").unwrap());