aboutsummaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorDavid Runge <david.runge@frqrec.com>2014-11-28 15:52:21 +0100
committerDavid Runge <david.runge@frqrec.com>2014-11-28 15:52:21 +0100
commit95e4d20a21054bcc3240e733662a5f2aaa331292 (patch)
tree8fd54e6e262f1c3a2800ce86c7d2571e9228a7b1 /bin
parente39c0420a829c4507989f88c446461b05af9b7aa (diff)
parent80fdb114410b477170a56061d60f5c6316043acc (diff)
downloaddotfiles-95e4d20a21054bcc3240e733662a5f2aaa331292.tar.gz
dotfiles-95e4d20a21054bcc3240e733662a5f2aaa331292.tar.bz2
dotfiles-95e4d20a21054bcc3240e733662a5f2aaa331292.tar.xz
dotfiles-95e4d20a21054bcc3240e733662a5f2aaa331292.zip
Merge branch 'master' of https://git.frqrec.com/git/dot
* 'master' of https://git.frqrec.com/git/dot: (22 commits) .gitignore: Adding further programs and their configs to the list, removing double entries mc panels.ini: Adding panels.ini. Qsampler.conf: Adding first config. .nvimrc: Adding config for NeoVim (symlink to Vim config). .linphonerc: Adding first linphone config file patchagerc: Adding first config file (still very messy with JACK session) mc ini: Adding first ini start_jack: Removing unneeded comments, adding TODO for external config file. checkip: Adding two more possible versions for checking global IP behind NAT. Version using dig now default. adjust_dpms: Merging script based programs into the same Array as the others. Adding -x to pidof check. khard.conf: Adding first khard config for several address books prompt_dvzrv_setup: Adding custom prompt based on steeef_simplified with additional ssh check and exit code printout. prompt.zsh: Switching to custom prompt 'dvzrv' functions.zsh: Making rsync functions more readable by splitting lines. export.zsh: Lowering REPORTTIME to 5 (seconds) aliases.zsh: Adding more systemd aliases. .zpreztorc: Adding highlighting modes. termite: Removing all non-valid settings. Adding transparency setting and colors again. redshift.conf: Choosing xrandr as backend. Setting transition time to 0. Using on screen 0 only. dpms: Adding script based programs to the list of programs. ...
Diffstat (limited to 'bin')
-rwxr-xr-xbin/adjust_dpms15
-rwxr-xr-xbin/checkip5
-rwxr-xr-xbin/start_jack5
3 files changed, 7 insertions, 18 deletions
diff --git a/bin/adjust_dpms b/bin/adjust_dpms
index 0391dba..c8e8a0f 100755
--- a/bin/adjust_dpms
+++ b/bin/adjust_dpms
@@ -18,10 +18,10 @@ else
exit 1
fi
-# loop all pre-compiled programs and check for running instances
+# loop all programs and check for running instances
for i in "${programs[@]}"
do
- pid=$(pidof $i)
+ pid=$(pidof -x $i)
re='^[0-9]+$'
if [[ $pid =~ $re ]]; then
echo "$i running ($pid)"
@@ -29,17 +29,6 @@ do
fi
done
-# loop all python2 run programs and check for running instances
-for i in "${python2[@]}"
-do
- pid=$(pidof python2 $i)
- re='^[0-9]+$'
- if [[ $pid =~ $re ]]; then
- echo "$i running ($pid)"
- blankoff=1
- fi
-done
-
# if valuable programs are running, don't use screen blanking
if [ $blankoff -gt 0 ]; then
echo "Some program requires screensaver to be off."
diff --git a/bin/checkip b/bin/checkip
index f7f2f4c..0e9d345 100755
--- a/bin/checkip
+++ b/bin/checkip
@@ -1,3 +1,4 @@
#!/bin/bash
-ip=`curl -s http://checkip.dyndns.org | sed 's/[a-zA-Z/<> :]//g'`
-echo "$ip"
+#echo "$(curl -s http://checkip.dyndns.org | sed 's/[a-zA-Z/<> :]//g')
+#wget -qO- http://ipecho.net/plain ; echo
+dig +short myip.opendns.com @resolver1.opendns.com
diff --git a/bin/start_jack b/bin/start_jack
index 735d5fa..0c99aab 100755
--- a/bin/start_jack
+++ b/bin/start_jack
@@ -1,5 +1,5 @@
#!/bin/sh
-
+# Script to start JACK as a user with several settings setup
export DISPLAY=:0.0
#jackd -P70 -p16 -t2000 -dalsa -dhw:0,0 -p128 -n3 -r44100 -s > .log/jackd.log 2>&1 &
@@ -23,6 +23,7 @@ case "$HOSTNAME" in
;;
"dvzrv")
DEVICE="/dev/fw1"
+ # TODO: Add settings from separate config file
if [[ -e $DEVICE && -r $DEVICE && -w $DEVICE ]]; then
echo "Setting up "$DEVICE" with JACK."
jack_control start
@@ -31,9 +32,7 @@ case "$HOSTNAME" in
jack_control ds firewire
jack_control dps device $DEVICE
jack_control dps rate 48000
- #jack_control dps rate 44100
jack_control dps nperiods 2
- #jack_control dps period 64
jack_control dps period 256
sleep 3
a2jmidid -e &