aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2013-01-22 21:09:35 -0500
committerDave Reisner <dreisner@archlinux.org>2013-01-22 21:09:35 -0500
commitfc87003435bbe4e4b235e0629e431492ec0dbb83 (patch)
tree55c8bc1511a0c3b5441c8e36fe5b76ac81fa82e3
parent0027e9422fa7205d0a50b995fbe172c35c9ce379 (diff)
downloadmirror-ponymix-fc87003435bbe4e4b235e0629e431492ec0dbb83.tar.gz
mirror-ponymix-fc87003435bbe4e4b235e0629e431492ec0dbb83.tar.bz2
mirror-ponymix-fc87003435bbe4e4b235e0629e431492ec0dbb83.zip
document --notify
-rw-r--r--bash-completion2
-rw-r--r--ponymix.14
-rw-r--r--ponymix.cc3
3 files changed, 7 insertions, 2 deletions
diff --git a/bash-completion b/bash-completion
index b9388c4..fc71557 100644
--- a/bash-completion
+++ b/bash-completion
@@ -9,7 +9,7 @@ in_array() {
_ponymix() {
local flags='-h --help -c --card -d --device -t --devtype
- --source --input --sink --output
+ -N --notify --source --input --sink --output
--sink-input --source-output'
local types='sink sink-input source source-output'
local verbs=(help defaults set-default list list-short
diff --git a/ponymix.1 b/ponymix.1
index a396db9..59365db 100644
--- a/ponymix.1
+++ b/ponymix.1
@@ -14,6 +14,10 @@ is used. Cards can be specified by name or numeric index.
.IP "\fB\-d\fR, \fB\-\-device\fR \fIDEVICE\fR"
Specify a device other than the default. Devices can be specified by name
or numeric index.
+.IP "\fB\-N\fR, \fB\-\-notify\fR"
+Create a libnotify notification for volume change events instead of printing
+the new volume to standard output. Requires compile time support for libnotify.
+Without support, this flag is a no-op.
.IP "\fB\-t\fR, \fB\-\-devtype\fR \fITYPE\fR"
Specify a device type to examine, usually in conjunction with the \fB--device\fR
flag. \fITYPE\fR must be one of \fIsink\fR, \fIsource\fR, \fIsink-input\fR, or
diff --git a/ponymix.cc b/ponymix.cc
index df8b1c7..48ae3dc 100644
--- a/ponymix.cc
+++ b/ponymix.cc
@@ -421,7 +421,7 @@ static int Kill(PulseClient& ponymix, int, char*[]) {
static const Command& string_to_command(const char* str) {
static std::map<string, const Command> actionmap = {
- // command name function arg min arg max
+ // command name function arg min arg max
{ "defaults", { ShowDefaults, { 0, 0 } } },
{ "list", { List, { 0, 0 } } },
{ "list-short", { ListShort, { 0, 0 } } },
@@ -462,6 +462,7 @@ static void usage() {
" -c, --card CARD target card (index or name)\n"
" -d, --device DEVICE target device (index or name)\n"
" -t, --devtype TYPE device type\n"
+ " -N, --notify use libnotify to announce volume changes\n"
" --source alias to -t source\n"
" --input alais to -t source\n"
" --sink alias to -t sink\n"