You are here

Add new comment

my Qjack.conf:
[Splitter]
AudioConnectView\sizes=203, 95, 214
MidiConnectView\sizes=34, 20, 34
AlsaConnectView\sizes=34, 20, 34
PatchbayView\sizes=34, 20, 34

[Settings]
Server=jackd
Realtime=true
SoftMode=false
Monitor=false
Shorts=false
NoMemLock=false
UnlockMem=false
HWMon=false
HWMeter=false
IgnoreHW=false
Priority=70
Frames=128
SampleRate=48000
Periods=2
WordLength=16
Wait=21333
Chan=0
Driver=alsa
Interface=hw:1
Audio=0
Dither=0
Timeout=5000
InDevice=
OutDevice=
InChannels=0
OutChannels=0
InLatency=0
OutLatency=0
StartDelay=0
Verbose=false
PortMax=256
MidiDriver=seq
realtime\Server=jackd
realtime\Realtime=true
realtime\SoftMode=false
realtime\Monitor=false
realtime\Shorts=false
realtime\NoMemLock=false
realtime\UnlockMem=false
realtime\HWMon=false
realtime\HWMeter=false
realtime\IgnoreHW=false
realtime\Priority=70
realtime\Frames=128
realtime\SampleRate=48000
realtime\Periods=2
realtime\WordLength=16
realtime\Wait=21333
realtime\Chan=0
realtime\Driver=alsa
realtime\Interface=hw:1
realtime\Audio=0
realtime\Dither=0
realtime\Timeout=5000
realtime\InDevice=
realtime\OutDevice=
realtime\InChannels=0
realtime\OutChannels=0
realtime\InLatency=0
realtime\OutLatency=0
realtime\StartDelay=0
realtime\Verbose=false
realtime\PortMax=256
realtime\MidiDriver=seq
mix_light\Server=jackd
mix_light\Realtime=true
mix_light\SoftMode=false
mix_light\Monitor=false
mix_light\Shorts=false
mix_light\NoMemLock=false
mix_light\UnlockMem=false
mix_light\HWMon=false
mix_light\HWMeter=false
mix_light\IgnoreHW=false
mix_light\Priority=70
mix_light\Frames=1024
mix_light\SampleRate=48000
mix_light\Periods=2
mix_light\WordLength=16
mix_light\Wait=21333
mix_light\Chan=0
mix_light\Driver=alsa
mix_light\Interface=hw:1
mix_light\Audio=0
mix_light\Dither=0
mix_light\Timeout=5000
mix_light\InDevice=
mix_light\OutDevice=
mix_light\InChannels=0
mix_light\OutChannels=0
mix_light\InLatency=0
mix_light\OutLatency=0
mix_light\StartDelay=0
mix_light\Verbose=false
mix_light\PortMax=256
mix_light\MidiDriver=seq
mix_hard\Server=jackd
mix_hard\Realtime=true
mix_hard\SoftMode=false
mix_hard\Monitor=false
mix_hard\Shorts=false
mix_hard\NoMemLock=false
mix_hard\UnlockMem=false
mix_hard\HWMon=false
mix_hard\HWMeter=false
mix_hard\IgnoreHW=false
mix_hard\Priority=70
mix_hard\Frames=2048
mix_hard\SampleRate=48000
mix_hard\Periods=4
mix_hard\WordLength=16
mix_hard\Wait=21333
mix_hard\Chan=0
mix_hard\Driver=alsa
mix_hard\Interface=hw:1
mix_hard\Audio=0
mix_hard\Dither=0
mix_hard\Timeout=5000
mix_hard\InDevice=
mix_hard\OutDevice=
mix_hard\InChannels=0
mix_hard\OutChannels=0
mix_hard\InLatency=0
mix_hard\OutLatency=0
mix_hard\StartDelay=0
mix_hard\Verbose=false
mix_hard\PortMax=256
mix_hard\MidiDriver=seq

[History]
ServerComboBox\Item1=jackd
ServerComboBox\Item2=jackdmp
ServerComboBox\Item3=jackstart
ServerComboBox\Item4=jackd-realtime
InterfaceComboBox\Item1=hw:1
InterfaceComboBox\Item2=(default)
InterfaceComboBox\Item3=hw:0
InterfaceComboBox\Item4=plughw:0
InterfaceComboBox\Item5=/dev/audio
InterfaceComboBox\Item6=/dev/dsp
InDeviceComboBox\Item1=(default)
InDeviceComboBox\Item2=hw:0
InDeviceComboBox\Item3=plughw:0
InDeviceComboBox\Item4=/dev/audio
InDeviceComboBox\Item5=/dev/dsp
OutDeviceComboBox\Item1=(default)
OutDeviceComboBox\Item2=hw:0
OutDeviceComboBox\Item3=plughw:0
OutDeviceComboBox\Item4=/dev/audio
OutDeviceComboBox\Item5=/dev/dsp
StartupScriptShellComboBox\Item1=pulse-into-jack pre-start
PostShutdownScriptShellComboBox\Item1=pulse-into-jack post-stop
XrunRegexComboBox\Item1=xrun of at least ([0-9|\\.]+) msecs
MessagesLogPathComboBox\Item1=qjackctl.log
ServerConfigNameComboBox\Item1=.jackdrc
StartupScriptShellComboBox\Item2="pulse-into-jack pre 2> /dev/null; killall pulseaudio;"
PostStartupScriptShellComboBox\Item1=pulse-into-jack post-start
ShutdownScriptShellComboBox\Item1=pulse-into-jack pre-stop
PostShutdownScriptShellComboBox\Item2="kill -s KILL `pidof pulseaudio`; pulseaudio -nF /etc/pulse/default.pa 2> /dev/null; pulse-into-jack post; "
PostStartupScriptShellComboBox\Item2="pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null; pulse-into-jack post; "
PostStartupScriptShellComboBox\Item3="pulse-into-jack post; pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null; pacmd set-default-sink jack_out; pacmd set-default-source jack_in"
PostStartupScriptShellComboBox\Item4="pulse-into-jack post; pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null; pacmd set-default-sink jack_out"
PostStartupScriptShellComboBox\Item5="pulse-into-jack post; pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null; pacmd set-default-sink jack_out # && [ -f /tmp/okskype ] && skype &"
PostStartupScriptShellComboBox\Item6="pulse-into-jack post; pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null # && [ -f /tmp/okskype ] && skype &"
PostStartupScriptShellComboBox\Item7=pulse-into-jack post #pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null # && [ -f /tmp/okskype ] && skype &
ActivePatchbayPathComboBox\Item1=/home/revol/.patchbay
StartupScriptShellComboBox\Item3="pulse-into-jack pre; killall pulseaudio;"
PostShutdownScriptShellComboBox\Item3="pulse-into-jack post; "
StartupScriptShellComboBox\Item4="pulse-into-jack pre; pulseaudio --kill 2> /dev/null"
PostShutdownScriptShellComboBox\Item4="sleep 1; pulseaudio -n -F /etc/pulse/default.pa 2> /dev/null; pulse-into-jack post; "
StartupScriptShellComboBox\Item5="pulse-into-jack pre; pulseaudio --kill 2> /dev/null # rm /tmp/okskype 2> /dev/null; killall skype && touch /tmp/okskype"
PostShutdownScriptShellComboBox\Item5="pulseaudio -n -F /etc/pulse/default.pa 2> /dev/null; pulse-into-jack post; "
StartupScriptShellComboBox\Item6="pulse-into-jack pre # rm /tmp/okskype 2> /dev/null; killall skype && touch /tmp/okskype; pulseaudio --kill 2> /dev/null"
PostStartupScriptShellComboBox\Item8=pulseaudio -D --realtime -n -F /home/revol/jackd.pa 2> /dev/null # && [ -f /tmp/okskype ] && skype &
StartupScriptShellComboBox\Item7="rm /tmp/okskype 2> /dev/null; killall skype && touch /tmp/okskype; pulseaudio --kill 2> /dev/null"
StartupScriptShellComboBox\Item8="rm /tmp/okskype 2> /dev/null; killall skype && touch /tmp/okskype; pulseaudio --kill"
ShutdownScriptShellComboBox\Item2="pulse-into-jack pre;"
PostShutdownScriptShellComboBox\Item6="kdialog --passivepopup \"ok\" 500; pulseaudio -n -F /etc/pulse/default.pa 2> /dev/null; pulse-into-jack post; "
PostShutdownScriptShellComboBox\Item7="kdialog --passivepopup \"ok\" 500; pulseaudio 2> /dev/null; pulse-into-jack post; "
PostShutdownScriptShellComboBox\Item8="pulseaudio; kdialog --passivepopup \"ok\" 5; pulse-into-jack post; "
ShutdownScriptShellComboBox\Item3="pulse-into-jack pre; killall pulseaudio;"
ShutdownScriptShellComboBox\Item4="pulse-into-jack pre; pulseaudio --kill"
ShutdownScriptShellComboBox\Item5="pulse-into-jack pre; pulseaudio --kill;"
ShutdownScriptShellComboBox\Item6="pulse-into-jack pre; pulseaudio --kill #killall skype 2> /dev/null;"
ShutdownScriptShellComboBox\Item7="pulse-into-jack pre #killall skype 2> /dev/null; pulseaudio --kill;"
ShutdownScriptShellComboBox\Item8="killall skype 2> /dev/null; pulseaudio --kill;"

[Geometry]
qjackctlMessagesForm\x=352
qjackctlMessagesForm\y=567
qjackctlMessagesForm\width=846
qjackctlMessagesForm\height=243
qjackctlMessagesForm\visible=false
qjackctlStatusForm\x=711
qjackctlStatusForm\y=716
qjackctlStatusForm\width=563
qjackctlStatusForm\height=236
qjackctlStatusForm\visible=false
qjackctlConnectionsForm\x=676
qjackctlConnectionsForm\y=635
qjackctlConnectionsForm\width=544
qjackctlConnectionsForm\height=282
qjackctlConnectionsForm\visible=true
qjackctlPatchbayForm\x=338
qjackctlPatchbayForm\y=468
qjackctlPatchbayForm\width=803
qjackctlPatchbayForm\height=369
qjackctlPatchbayForm\visible=false
qjackctlMainForm\x=936
qjackctlMainForm\y=827
qjackctlMainForm\width=300
qjackctlMainForm\height=102
qjackctlMainForm\visible=false

[Program]
Version=0.3.6

[Presets]
DefPreset=realtime
Preset1=mix_hard
Preset2=mix_light
Preset3=realtime

[Options]
StartJack=true
StartupScript=true
StartupScriptShell=pulse-into-jack pre-start
PostStartupScript=true
PostStartupScriptShell=pulse-into-jack post-start
ShutdownScript=true
ShutdownScriptShell=pulse-into-jack pre-stop
PostShutdownScript=true
PostShutdownScriptShell=pulse-into-jack post-stop
StdoutCapture=true
XrunRegex=xrun of at least ([0-9|\\.]+) msecs
XrunIgnoreFirst=false
ActivePatchbay=true
ActivePatchbayPath=/home/revol/.patchbay
MessagesLog=false
MessagesLogPath=qjackctl.log
BezierLines=false
TimeDisplay=0
TimeFormat=0
MessagesFont="Bitstream Vera Sans,10,-1,5,50,0,0,0,0,0"
MessagesLimit=true
MessagesLimitLines=1000
DisplayFont1="Bitstream Vera Sans,12,-1,5,75,0,0,0,0,0"
DisplayFont2="Bitstream Vera Sans,10,-1,5,50,0,0,0,0,0"
DisplayEffect=true
DisplayBlink=true
JackClientPortAlias=0
ConnectionsIconSize=0
ConnectionsFont="Bitstream Vera Sans,10,-1,5,50,0,0,0,0,0"
QueryClose=false
KeepOnTop=false
SystemTray=true
StartMinimized=true
DelayedSetup=false
ServerConfig=true
ServerConfigName=.jackdrc
ServerConfigTemp=false
QueryShutdown=false
AlsaSeqEnabled=true
AliasesEnabled=false
AliasesEditing=false
LeftButtons=true
RightButtons=true
TransportButtons=true
TextLabels=false
BaseFontSize=0
DBusEnabled=true
Singleton=true

[Defaults]
PatchbayPath=/home/revol/.patchbay

[Patchbays]
Patchbay1=/home/revol/.patchbay
My script:
#!/bin/bash
which pacmd &> /dev/null
[ $? -eq 1 ] && echo "pacmd not present in your PATH, please install pulseaudio-utils" && exit 1

STORE_FILE="/tmp/pulse-into-jack-apps"
PRE_POST="`echo $1 | cut -f1 -d "-"`"
START_STOP="`echo $1 | cut -f2 -d "-"`"

pre() {
LISTA_APPZ=`pacmd list-clients |grep application.process.binary|grep -o -e "\"[A-Za-z0-9]*\""|sed 's/\"//g'|sed -e 's/\n/\ /g'`
echo -e "Executing \"pre\" action for pulse-into-jack\nKilling and storing applications connected to PulseAudio"
echo -ne $LISTA_APPZ" " > $STORE_FILE
echo -e "\n *** ***"
echo $LISTA_APPZ
echo -e " *** ***"
kill -s KILL `pidof $LISTA_APPZ` 2> /dev/null
}

post() {
echo -e "Executing \"post\" action for pulse-into-jack\nRestarting stored applications connected to PulseAudio"
[ -f $STORE_FILE ] && echo -e "\n *** ***" && cat $STORE_FILE && echo -e "\n *** ***"
if [ "x`cat $STORE_FILE|sed 's/ //g' 2> /dev/null`" != "x" ]
then
cat $STORE_FILE|sed 's/\ / \&\n/g' > $STORE_FILE"tmp" && rm $STORE_FILE
. $STORE_FILE"tmp" 2> /dev/null
rm $STORE_FILE"tmp"
fi
}

case $1 in
"pre-start")
pre
kill -s KILL `pidof pulseaudio` 2> /dev/null
;;
"pre-stop")
pre
kill -s KILL `pidof pulseaudio` 2> /dev/null
;;
"post-start")
pulseaudio -D --realtime -n -F /etc/pulse/jackd.pa 2> /dev/null &
post
;;
"post-stop")
# pulseaudio 2> /dev/null &
post
;;
*)
echo -e "Usage:\npulse-into-jack pre-start # To kill and store apps connected to PulseAudio\npulse-into-jack post-start # To restart stored apps, then start pulseaudio in Jack environment\npulse-into-jack pre-stop # To kill and store apps connected to PulseAudio\npulse-into-jack post-stop # To restart stored apps, then start pulseaudio with default settings"
exit 1
;;
esac

exit 0

If I start/stop server everything works well, but when I quit the app, post-shutdown script isn't executed.,
qjackctl --version
Qt: 4.5.3
QjackCtl: 0.3.6