Commits

Toby Davies  committed 578ddc0

Cleanup path and fpath

  • Participants
  • Parent commits 5378b54

Comments (0)

Files changed (12)

+#!/usr/bin/zsh
+
+X=()
+if (nmcli -t -f name con status | grep -q "UniWireless") ; then
+    X=("--proxy-pac-url=http://www.unimelb.edu.au/cgi-bin/proxy.pac")
+    echo "foo" >> ~/foo.bar
+else
+    echo "bar" >> ~/foo.bar
+fi
+
+echo chromium-browser $X $@
+
+chromium-browser $X $@
+#!/usr/bin/zsh
+if [ "$TTY" ] ; then
+    X=("-nw")
+else
+    urxvt -e "emacs -nw"
+fi
+emacsclient $X -e "(shell-apropos-buffer \"${@}\")"

File bin/mozilla

-/usr/bin/chromium-browser
+#!/usr/bin/zsh
+
+if (( $# > 0)); then
+    Fs=${~@}
+fi
+if [ -z "$TTY" ] ; then
+    urxvt -e $0 $Fs&!
+    sleep 0.5
+fi
+echo $Fs;
+if [ $Fs ] ; then 
+    {for f in ${Fs}; do
+	emacsclient -nw $f 2>&/dev/null &
+	done}
+else
+    emacsclient -nw &
+fi
+
+wait
+#!/usr/bin/zsh
+if [[ -f $1 ]]; then
+    chromium-browser --app=file://${1:a};
+else
+    chromium-browser --app=${1};
+fi

File fbin/activate

-#!/usr/bin/zsh
-xdotool windowactivate $(xdotool search $@ | head -1)

File fbin/browser

-#!/usr/bin/zsh
-
-X=()
-if (nmcli -t -f name con status | grep -q "UniWireless") ; then
-    X=("--proxy-pac-url=http://www.unimelb.edu.au/cgi-bin/proxy.pac")
-    echo "foo" >> ~/foo.bar
-else
-    echo "bar" >> ~/foo.bar
-fi
-
-echo chromium-browser $X $@
-
-chromium-browser $X $@

File fbin/man

-#!/usr/bin/zsh
-if [ "$TTY" ] ; then
-    X=("-nw")
-else
-    urxvt -e "emacs -nw"
-fi
-emacsclient $X -e "(shell-apropos-buffer \"${@}\")"

File fbin/maximize

-#!/usr/bin/zsh
-XDIMS=($(xdpyinfo -display $DISPLAY | grep dimensions | sed 's/^[^0-9]*\([0-9]*\)x\([0-9]*\)\s*pixels.*/\1 \2/'))
-for wid in ${$(xdotool search $@)}; do
-    echo $wid
-    xdotool windowsize $wid $XDIMS[1] $XDIMS[2]
-done

File fbin/start_emacs

-#!/usr/bin/zsh
-emacs_started(){
-    emacsclient --eval '()' 2>&/dev/null
-}
-
-emacs_started || 
-{=emacs&!;
-    t=20;
-    until {emacs_started || (( (t--)<0 ))}; do
-	sleep $CLIENT_RETRY_DELAY;
-    done;
-    if ((t<0)); then
-	echo "Cannot connect to emacs, ensure server mode enabled" 1>&2;
-	return -1;
-    fi}
-
-maximize --name emacs

File fbin/visit

-#!/usr/bin/zsh
-
-if (( $# > 0)); then
-    Fs=${~@}
-fi
-if [ -z "$TTY" ] ; then
-    urxvt -e $0 $Fs&!
-    sleep 0.5
-fi
-echo $Fs;
-if [ $Fs ] ; then 
-    {for f in ${Fs}; do
-	emacsclient -nw $f 2>&/dev/null &
-	done}
-else
-    emacsclient -nw &
-fi
-
-wait

File fbin/webapp

-#!/usr/bin/zsh
-if [[ -f $1 ]]; then
-    chromium-browser --app=file://${1:a};
-else
-    chromium-browser --app=${1};
-fi