mirror of
https://github.com/SuperBFG7/ympd
synced 2025-07-05 19:32:52 +00:00
New Settings API replaces Options API, Smaller Stats API
This commit is contained in:
parent
f122355c38
commit
8c423f4c77
@ -515,7 +515,7 @@
|
|||||||
<h4><a class="text-success" href="https://github.com/jcorporation/ympd"><span class="material-icons">play_circle_outline</span> myMPD</a> – <small>MPD Web GUI - written in C, utilizing Websockets and Bootstrap/JS</small></h4>
|
<h4><a class="text-success" href="https://github.com/jcorporation/ympd"><span class="material-icons">play_circle_outline</span> myMPD</a> – <small>MPD Web GUI - written in C, utilizing Websockets and Bootstrap/JS</small></h4>
|
||||||
<p>myMPD is a lightweight MPD web client that runs without a dedicated webserver or interpreter. It's tuned for minimal resource usage and requires only very litte dependencies. myMPD is a fork of <a style="color:#28a745" href="http://www.ympd.org">ympd</a>.</p>
|
<p>myMPD is a lightweight MPD web client that runs without a dedicated webserver or interpreter. It's tuned for minimal resource usage and requires only very litte dependencies. myMPD is a fork of <a style="color:#28a745" href="http://www.ympd.org">ympd</a>.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Version: 2.1.1</li>
|
<li>Version: <span id="mympdVersion"></span></li>
|
||||||
<li>Homepage: <a class="text-success" target="_blank" href="https://github.com/jcorporation/mympd">https://github.com/jcorporation/mympd</a></li>
|
<li>Homepage: <a class="text-success" target="_blank" href="https://github.com/jcorporation/mympd">https://github.com/jcorporation/mympd</a></li>
|
||||||
<li>Autor: Juergen Mang <<a class="text-success" href="mailto:mail@jcgames.de">mail@jcgames.de</a>></li>
|
<li>Autor: Juergen Mang <<a class="text-success" href="mailto:mail@jcgames.de">mail@jcgames.de</a>></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
129
htdocs/js/mpd.js
129
htdocs/js/mpd.js
@ -210,11 +210,16 @@ $(document).ready(function(){
|
|||||||
|
|
||||||
$('#about').on('shown.bs.modal', function () {
|
$('#about').on('shown.bs.modal', function () {
|
||||||
socket.send("MPD_API_GET_STATS");
|
socket.send("MPD_API_GET_STATS");
|
||||||
})
|
})
|
||||||
|
|
||||||
|
$('#settings').on('shown.bs.modal', function () {
|
||||||
|
socket.send("MPD_API_GET_SETTINGS");
|
||||||
|
})
|
||||||
|
|
||||||
$('#addstream').on('shown.bs.modal', function () {
|
$('#addstream').on('shown.bs.modal', function () {
|
||||||
$('#streamurl').focus();
|
$('#streamurl').focus();
|
||||||
})
|
})
|
||||||
|
|
||||||
$('#addstream form').on('submit', function (e) {
|
$('#addstream form').on('submit', function (e) {
|
||||||
addStream();
|
addStream();
|
||||||
});
|
});
|
||||||
@ -249,8 +254,8 @@ function webSocketConnect() {
|
|||||||
showNotification('Connected to myMPD','','','success');
|
showNotification('Connected to myMPD','','','success');
|
||||||
$('#modalConnectionError').modal('hide');
|
$('#modalConnectionError').modal('hide');
|
||||||
app.run();
|
app.run();
|
||||||
/* emit request for mympd options */
|
/* emit request for mympd settings */
|
||||||
socket.send('MPD_API_GET_OPTIONS');
|
socket.send('MPD_API_GET_SETTINGS');
|
||||||
/* emit initial request for output names */
|
/* emit initial request for output names */
|
||||||
socket.send('MPD_API_GET_OUTPUTS');
|
socket.send('MPD_API_GET_OUTPUTS');
|
||||||
|
|
||||||
@ -534,62 +539,7 @@ function webSocketConnect() {
|
|||||||
$('#queueList > tbody > tr[trackid='+obj.data.currentsongid+'] > td').eq(0).addClass('material-icons').text('play_arrow');
|
$('#queueList > tbody > tr[trackid='+obj.data.currentsongid+'] > td').eq(0).addClass('material-icons').text('play_arrow');
|
||||||
$('#queueList > tbody > tr[trackid='+obj.data.currentsongid+']').addClass('active').css("font-weight", "bold");
|
$('#queueList > tbody > tr[trackid='+obj.data.currentsongid+']').addClass('active').css("font-weight", "bold");
|
||||||
|
|
||||||
if(obj.data.random)
|
|
||||||
$('#btnrandom').removeClass('btn-secondary').addClass("btn-success")
|
|
||||||
else
|
|
||||||
$('#btnrandom').removeClass("btn-success").addClass("btn-secondary");
|
|
||||||
|
|
||||||
if(obj.data.consume)
|
|
||||||
$('#btnconsume').removeClass('btn-secondary').addClass("btn-success")
|
|
||||||
else
|
|
||||||
$('#btnconsume').removeClass("btn-success").addClass("btn-secondary");
|
|
||||||
|
|
||||||
if(obj.data.single)
|
|
||||||
$('#btnsingle').removeClass('btn-secondary').addClass("btn-success")
|
|
||||||
else
|
|
||||||
$('#btnsingle').removeClass("btn-success").addClass("btn-secondary");
|
|
||||||
|
|
||||||
if(obj.data.crossfade != undefined) {
|
|
||||||
if (!last_state) {
|
|
||||||
$('#inputCrossfade').removeAttr('disabled');
|
|
||||||
$('#inputCrossfade').val(obj.data.crossfade);
|
|
||||||
} else if(obj.data.crossfade != last_state.data.crossfade) {
|
|
||||||
$('#inputCrossfade').removeAttr('disabled');
|
|
||||||
$('#inputCrossfade').val(obj.data.crossfade);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
$('#inputCrossfade').attr('disabled', 'disabled');
|
|
||||||
}
|
|
||||||
|
|
||||||
if(obj.data.mixrampdb != undefined) {
|
|
||||||
if (!last_state) {
|
|
||||||
$('#inputMixrampdb').removeAttr('disabled');
|
|
||||||
$('#inputMixrampdb').val(obj.data.mixrampdb);
|
|
||||||
} else if(obj.data.mixrampdb != last_state.data.mixrampdb) {
|
|
||||||
$('#inputMixrampdb').removeAttr('disabled');
|
|
||||||
$('#inputMixrampdb').val(obj.data.mixrampdb);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
$('#inputMixrampdb').attr('disabled', 'disabled');
|
|
||||||
}
|
|
||||||
|
|
||||||
if(obj.data.mixrampdelay != undefined) {
|
|
||||||
if (!last_state) {
|
|
||||||
$('#inputMixrampdelay').removeAttr('disabled');
|
|
||||||
$('#inputMixrampdelay').val(obj.data.mixrampdelay);
|
|
||||||
} else if(obj.data.mixrampdelay != last_state.data.mixrampdelay) {
|
|
||||||
$('#inputMixrampdelay').removeAttr('disabled');
|
|
||||||
$('#inputMixrampdelay').val(obj.data.mixrampdelay);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
$('#inputMixrampdb').attr('disabled', 'disabled');
|
|
||||||
}
|
|
||||||
|
|
||||||
if(obj.data.repeat)
|
|
||||||
$('#btnrepeat').removeClass('btn-secondary').addClass("btn-success")
|
|
||||||
else
|
|
||||||
$('#btnrepeat').removeClass("btn-success").addClass("btn-secondary");
|
|
||||||
|
|
||||||
last_state = obj;
|
last_state = obj;
|
||||||
break;
|
break;
|
||||||
case 'outputnames':
|
case 'outputnames':
|
||||||
@ -629,7 +579,48 @@ function webSocketConnect() {
|
|||||||
case "song_change":
|
case "song_change":
|
||||||
songChange(obj.data.title, obj.data.artist, obj.data.album, obj.data.uri);
|
songChange(obj.data.title, obj.data.artist, obj.data.album, obj.data.uri);
|
||||||
break;
|
break;
|
||||||
case 'mpdoptions':
|
case 'settings':
|
||||||
|
if(obj.data.random)
|
||||||
|
$('#btnrandom').removeClass('btn-secondary').addClass("btn-success")
|
||||||
|
else
|
||||||
|
$('#btnrandom').removeClass("btn-success").addClass("btn-secondary");
|
||||||
|
|
||||||
|
if(obj.data.consume)
|
||||||
|
$('#btnconsume').removeClass('btn-secondary').addClass("btn-success")
|
||||||
|
else
|
||||||
|
$('#btnconsume').removeClass("btn-success").addClass("btn-secondary");
|
||||||
|
|
||||||
|
if(obj.data.single)
|
||||||
|
$('#btnsingle').removeClass('btn-secondary').addClass("btn-success")
|
||||||
|
else
|
||||||
|
$('#btnsingle').removeClass("btn-success").addClass("btn-secondary");
|
||||||
|
|
||||||
|
if(obj.data.crossfade != undefined) {
|
||||||
|
$('#inputCrossfade').removeAttr('disabled');
|
||||||
|
$('#inputCrossfade').val(obj.data.crossfade);
|
||||||
|
} else {
|
||||||
|
$('#inputCrossfade').attr('disabled', 'disabled');
|
||||||
|
}
|
||||||
|
|
||||||
|
if(obj.data.mixrampdb != undefined) {
|
||||||
|
$('#inputMixrampdb').removeAttr('disabled');
|
||||||
|
$('#inputMixrampdb').val(obj.data.mixrampdb);
|
||||||
|
} else {
|
||||||
|
$('#inputMixrampdb').attr('disabled', 'disabled');
|
||||||
|
}
|
||||||
|
|
||||||
|
if(obj.data.mixrampdelay != undefined) {
|
||||||
|
$('#inputMixrampdelay').removeAttr('disabled');
|
||||||
|
$('#inputMixrampdelay').val(obj.data.mixrampdelay);
|
||||||
|
} else {
|
||||||
|
$('#inputMixrampdb').attr('disabled', 'disabled');
|
||||||
|
}
|
||||||
|
|
||||||
|
if(obj.data.repeat)
|
||||||
|
$('#btnrepeat').removeClass('btn-secondary').addClass("btn-success")
|
||||||
|
else
|
||||||
|
$('#btnrepeat').removeClass("btn-success").addClass("btn-secondary");
|
||||||
|
|
||||||
setLocalStream(obj.data.mpdhost,obj.data.streamport);
|
setLocalStream(obj.data.mpdhost,obj.data.streamport);
|
||||||
coverImageFile=obj.data.coverimage;
|
coverImageFile=obj.data.coverimage;
|
||||||
break;
|
break;
|
||||||
@ -642,6 +633,7 @@ function webSocketConnect() {
|
|||||||
$('#mpdstats_uptime').text(beautifyDuration(obj.data.uptime));
|
$('#mpdstats_uptime').text(beautifyDuration(obj.data.uptime));
|
||||||
var d = new Date(obj.data.dbupdated * 1000);
|
var d = new Date(obj.data.dbupdated * 1000);
|
||||||
$('#mpdstats_dbupdated').text(d.toUTCString());
|
$('#mpdstats_dbupdated').text(d.toUTCString());
|
||||||
|
$('#mympdVersion').text(obj.data.mympd_version);
|
||||||
break;
|
break;
|
||||||
case 'error':
|
case 'error':
|
||||||
showNotification(obj.data,'','','danger');
|
showNotification(obj.data,'','','danger');
|
||||||
@ -810,20 +802,31 @@ function basename(path) {
|
|||||||
return path.split('/').reverse()[0];
|
return path.split('/').reverse()[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
$('#btnrandom').on('click', function (e) {
|
function toggleBtn(btn) {
|
||||||
socket.send("MPD_API_TOGGLE_RANDOM," + ($(this).hasClass('btn-success') ? 0 : 1));
|
if ($(btn).hasClass('btn-success')) {
|
||||||
|
$(btn).removeClass('btn-success').addClass('btn-secondary');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$(btn).removeClass('btn-secondary').addClass('btn-success');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$('#btnrandom').on('click', function (e) {
|
||||||
|
socket.send("MPD_API_TOGGLE_RANDOM," + ($(this).hasClass('btn-success') ? 0 : 1));
|
||||||
|
toggleBtn(this);
|
||||||
});
|
});
|
||||||
$('#btnconsume').on('click', function (e) {
|
$('#btnconsume').on('click', function (e) {
|
||||||
socket.send("MPD_API_TOGGLE_CONSUME," + ($(this).hasClass('btn-success') ? 0 : 1));
|
socket.send("MPD_API_TOGGLE_CONSUME," + ($(this).hasClass('btn-success') ? 0 : 1));
|
||||||
|
toggleBtn(this);
|
||||||
});
|
});
|
||||||
$('#btnsingle').on('click', function (e) {
|
$('#btnsingle').on('click', function (e) {
|
||||||
socket.send("MPD_API_TOGGLE_SINGLE," + ($(this).hasClass('btn-success') ? 0 : 1));
|
socket.send("MPD_API_TOGGLE_SINGLE," + ($(this).hasClass('btn-success') ? 0 : 1));
|
||||||
|
toggleBtn(this);
|
||||||
});
|
});
|
||||||
|
|
||||||
$('#btnrepeat').on('click', function (e) {
|
$('#btnrepeat').on('click', function (e) {
|
||||||
socket.send("MPD_API_TOGGLE_REPEAT," + ($(this).hasClass('btn-success') ? 0 : 1));
|
socket.send("MPD_API_TOGGLE_REPEAT," + ($(this).hasClass('btn-success') ? 0 : 1));
|
||||||
|
toggleBtn(this);
|
||||||
});
|
});
|
||||||
|
|
||||||
function confirmSettings() {
|
function confirmSettings() {
|
||||||
|
@ -25,8 +25,9 @@
|
|||||||
#ifndef __CONFIG_H__
|
#ifndef __CONFIG_H__
|
||||||
#define __CONFIG_H__
|
#define __CONFIG_H__
|
||||||
|
|
||||||
#define YMPD_VERSION_MAJOR ${CPACK_PACKAGE_VERSION_MAJOR}
|
#define MYMPD_VERSION_MAJOR ${CPACK_PACKAGE_VERSION_MAJOR}
|
||||||
#define YMPD_VERSION_MINOR ${CPACK_PACKAGE_VERSION_MINOR}
|
#define MYMPD_VERSION_MINOR ${CPACK_PACKAGE_VERSION_MINOR}
|
||||||
#define YMPD_VERSION_PATCH ${CPACK_PACKAGE_VERSION_PATCH}
|
#define MYMPD_VERSION_PATCH ${CPACK_PACKAGE_VERSION_PATCH}
|
||||||
|
#define MYMPD_VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}"
|
||||||
#define SRC_PATH "${ASSETS_PATH}"
|
#define SRC_PATH "${ASSETS_PATH}"
|
||||||
#endif
|
#endif
|
||||||
|
@ -331,11 +331,8 @@ out_send_message:
|
|||||||
out_rm_playlist:
|
out_rm_playlist:
|
||||||
free(p_charbuf);
|
free(p_charbuf);
|
||||||
break;
|
break;
|
||||||
case MPD_API_GET_OPTIONS:
|
case MPD_API_GET_SETTINGS:
|
||||||
n = snprintf(mpd.buf, MAX_SIZE, "{\"type\":\"mpdoptions\", \"data\": "
|
n = mympd_put_settings(mpd.buf);
|
||||||
"{\"mpdhost\" : \"%s\", \"mpdport\": \"%d\", \"passwort_set\": %s, "
|
|
||||||
"\"streamport\": \"%d\",\"coverimage\": \"%s\"}"
|
|
||||||
"}", mpd.host, mpd.port, mpd.password ? "true" : "false", streamport, coverimage);
|
|
||||||
break;
|
break;
|
||||||
case MPD_API_GET_STATS:
|
case MPD_API_GET_STATS:
|
||||||
n = mympd_get_stats(mpd.buf);
|
n = mympd_get_stats(mpd.buf);
|
||||||
@ -563,26 +560,17 @@ int mpd_put_state(char *buffer, int *current_song_id, int *next_song_id, unsign
|
|||||||
|
|
||||||
len = snprintf(buffer, MAX_SIZE,
|
len = snprintf(buffer, MAX_SIZE,
|
||||||
"{\"type\":\"state\", \"data\":{"
|
"{\"type\":\"state\", \"data\":{"
|
||||||
" \"state\":%d, \"volume\":%d, \"repeat\":%d,"
|
"\"state\":%d, \"volume\":%d, \"songpos\": %d, \"elapsedTime\": %d, "
|
||||||
" \"single\":%d, \"crossfade\":%d, \"consume\":%d, \"random\":%d, "
|
"\"totalTime\":%d, \"currentsongid\": %d, \"kbitrate\": %d, "
|
||||||
" \"songpos\": %d, \"elapsedTime\": %d, \"totalTime\":%d, "
|
"\"queue_length\": %d, \"nextsongpos\": %d"
|
||||||
" \"currentsongid\": %d, \"kbitrate\": %d, \"mixrampdb\": %lf, "
|
|
||||||
" \"mixrampdelay\": %lf, \"queue_length\": %d, \"nextsongpos\": %d"
|
|
||||||
"}}",
|
"}}",
|
||||||
mpd_status_get_state(status),
|
mpd_status_get_state(status),
|
||||||
mpd_status_get_volume(status),
|
mpd_status_get_volume(status),
|
||||||
mpd_status_get_repeat(status),
|
|
||||||
mpd_status_get_single(status),
|
|
||||||
mpd_status_get_crossfade(status),
|
|
||||||
mpd_status_get_consume(status),
|
|
||||||
mpd_status_get_random(status),
|
|
||||||
mpd_status_get_song_pos(status),
|
mpd_status_get_song_pos(status),
|
||||||
mpd_status_get_elapsed_time(status),
|
mpd_status_get_elapsed_time(status),
|
||||||
mpd_status_get_total_time(status),
|
mpd_status_get_total_time(status),
|
||||||
mpd_status_get_song_id(status),
|
mpd_status_get_song_id(status),
|
||||||
mpd_status_get_kbit_rate(status),
|
mpd_status_get_kbit_rate(status),
|
||||||
mpd_status_get_mixrampdb(status),
|
|
||||||
mpd_status_get_mixrampdelay(status),
|
|
||||||
mpd_status_get_queue_length(status),
|
mpd_status_get_queue_length(status),
|
||||||
mpd_status_get_next_song_pos(status)
|
mpd_status_get_next_song_pos(status)
|
||||||
);
|
);
|
||||||
@ -594,6 +582,38 @@ int mpd_put_state(char *buffer, int *current_song_id, int *next_song_id, unsign
|
|||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int mympd_put_settings(char *buffer)
|
||||||
|
{
|
||||||
|
struct mpd_status *status;
|
||||||
|
int len;
|
||||||
|
|
||||||
|
status = mpd_run_status(mpd.conn);
|
||||||
|
if (!status) {
|
||||||
|
fprintf(stderr, "MPD mpd_run_status: %s\n", mpd_connection_get_error_message(mpd.conn));
|
||||||
|
mpd.conn_state = MPD_FAILURE;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
len = snprintf(buffer, MAX_SIZE,
|
||||||
|
"{\"type\":\"settings\", \"data\":{"
|
||||||
|
"\"repeat\":%d, \"single\":%d, \"crossfade\":%d, \"consume\":%d, \"random\":%d, "
|
||||||
|
"\"mixrampdb\": %lf, \"mixrampdelay\": %lf, \"mpdhost\" : \"%s\", \"mpdport\": \"%d\", \"passwort_set\": %s, "
|
||||||
|
"\"streamport\": \"%d\",\"coverimage\": \"%s\""
|
||||||
|
"}}",
|
||||||
|
mpd_status_get_repeat(status),
|
||||||
|
mpd_status_get_single(status),
|
||||||
|
mpd_status_get_crossfade(status),
|
||||||
|
mpd_status_get_consume(status),
|
||||||
|
mpd_status_get_random(status),
|
||||||
|
mpd_status_get_mixrampdb(status),
|
||||||
|
mpd_status_get_mixrampdelay(status),
|
||||||
|
mpd.host, mpd.port, mpd.password ? "true" : "false", streamport, coverimage
|
||||||
|
);
|
||||||
|
mpd_status_free(status);
|
||||||
|
return len;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
int mpd_put_outputs(char *buffer, int names)
|
int mpd_put_outputs(char *buffer, int names)
|
||||||
{
|
{
|
||||||
struct mpd_output *out;
|
struct mpd_output *out;
|
||||||
@ -964,7 +984,9 @@ int mympd_get_stats(char *buffer)
|
|||||||
cur += json_emit_raw_str(cur, end - cur, ",\"dbupdated\":");
|
cur += json_emit_raw_str(cur, end - cur, ",\"dbupdated\":");
|
||||||
cur += json_emit_int(cur, end - cur, mpd_stats_get_db_update_time(stats));
|
cur += json_emit_int(cur, end - cur, mpd_stats_get_db_update_time(stats));
|
||||||
cur += json_emit_raw_str(cur, end - cur, ",\"dbplaytime\":");
|
cur += json_emit_raw_str(cur, end - cur, ",\"dbplaytime\":");
|
||||||
cur += json_emit_int(cur, end - cur, mpd_stats_get_db_play_time(stats));
|
cur += json_emit_int(cur, end - cur, mpd_stats_get_db_play_time(stats));
|
||||||
|
cur += json_emit_raw_str(cur, end - cur, ",\"mympd_version\":");
|
||||||
|
cur += json_emit_quoted_str(cur, end - cur, MYMPD_VERSION);
|
||||||
cur += json_emit_raw_str(cur, end - cur, "}}");
|
cur += json_emit_raw_str(cur, end - cur, "}}");
|
||||||
|
|
||||||
mpd_stats_free(stats);
|
mpd_stats_free(stats);
|
||||||
|
@ -72,7 +72,7 @@
|
|||||||
X(MPD_API_TOGGLE_SINGLE) \
|
X(MPD_API_TOGGLE_SINGLE) \
|
||||||
X(MPD_API_SET_CROSSFADE) \
|
X(MPD_API_SET_CROSSFADE) \
|
||||||
X(MPD_API_TOGGLE_REPEAT) \
|
X(MPD_API_TOGGLE_REPEAT) \
|
||||||
X(MPD_API_GET_OPTIONS) \
|
X(MPD_API_GET_SETTINGS) \
|
||||||
X(MPD_API_SEND_SHUFFLE) \
|
X(MPD_API_SEND_SHUFFLE) \
|
||||||
X(MPD_API_GET_STATS) \
|
X(MPD_API_GET_STATS) \
|
||||||
X(MPD_API_SET_MIXRAMPDB) \
|
X(MPD_API_SET_MIXRAMPDB) \
|
||||||
@ -131,7 +131,8 @@ int mpd_put_playlists(char *buffer, unsigned int offset);
|
|||||||
int mpd_put_browse(char *buffer, char *path, unsigned int offset);
|
int mpd_put_browse(char *buffer, char *path, unsigned int offset);
|
||||||
int mpd_search(char *buffer, char *mpdtagtype, unsigned int offset, char *searchstr);
|
int mpd_search(char *buffer, char *mpdtagtype, unsigned int offset, char *searchstr);
|
||||||
int mpd_search_queue(char *buffer, char *mpdtagtype, unsigned int offset, char *searchstr);
|
int mpd_search_queue(char *buffer, char *mpdtagtype, unsigned int offset, char *searchstr);
|
||||||
int mympd_get_stats();
|
int mympd_get_stats(char *buffer);
|
||||||
|
int mympd_put_settings(char *buffer);
|
||||||
void mpd_disconnect();
|
void mpd_disconnect();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -146,8 +146,8 @@ int main(int argc, char **argv)
|
|||||||
case 'v':
|
case 'v':
|
||||||
fprintf(stdout, "myMPD %d.%d.%d\n"
|
fprintf(stdout, "myMPD %d.%d.%d\n"
|
||||||
"Copyright (C) 2018 Juergen Mang <mail@jcgames.de>\n"
|
"Copyright (C) 2018 Juergen Mang <mail@jcgames.de>\n"
|
||||||
"built " __DATE__ " "__TIME__ " ("__VERSION__")\n",
|
"built " __DATE__ " "__TIME__ "\n",
|
||||||
YMPD_VERSION_MAJOR, YMPD_VERSION_MINOR, YMPD_VERSION_PATCH);
|
MYMPD_VERSION_MAJOR, MYMPD_VERSION_MINOR, MYMPD_VERSION_PATCH);
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user