From 10af23b979c35905687c6a1e9c213aec33773f8e Mon Sep 17 00:00:00 2001
From: Přemysl Janouch
Date: Wed, 12 Oct 2016 18:19:21 +0200
Subject: WIP
---
dwmstatus.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/dwmstatus.c b/dwmstatus.c
index da2b78f..799a585 100644
--- a/dwmstatus.c
+++ b/dwmstatus.c
@@ -968,6 +968,10 @@ static struct simple_config_item g_config_table[] =
{ "mpd_service", "6600", "MPD service name or port" },
{ "mpd_password", NULL, "MPD password" },
+ { "last_fm_key", NULL, "last.fm API key" },
+ { "last_fm_secret", NULL, "last.fm API secret" },
+ { "last_fm_session", NULL, "last.fm API session ID" },
+
{ "nut_enabled", "off", "NUT UPS status reading enabled" },
{ "nut_load_thld", "50", "NUT threshold for load display" },
@@ -2212,6 +2216,7 @@ main (int argc, char *argv[])
{ 'w', "write-default-cfg", "FILENAME",
OPT_OPTIONAL_ARG | OPT_LONG_ONLY,
"write a default configuration file and exit" },
+ { 's', "init-session", NULL, 0, "start a last.fm API session" },
{ 0, NULL, NULL, 0, NULL }
};
@@ -2234,6 +2239,9 @@ main (int argc, char *argv[])
case 'w':
call_simple_config_write_default (optarg, g_config_table);
exit (EXIT_SUCCESS);
+ case 's':
+ // TODO: authenticate with last.fm using configuration
+ exit (EXIT_SUCCESS);
default:
print_error ("wrong options");
opt_handler_usage (&oh, stderr);
--
cgit v1.2.3-70-g09d2