summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaghavendra D Prabhu <raghu.prabhu13@gmail.com>2011-03-13 19:06:50 +0530
committerRaghavendra D Prabhu <raghu.prabhu13@gmail.com>2011-03-13 19:06:50 +0530
commita4a45af197578fbe06e6d81f4c479776d732272b (patch)
treec1013881be7f4eff33197a8df75c3bfc35f3df7b
parent5ec75ea891c9b44cdd2d7a3e0c29b4d08dff2b2a (diff)
downloadScripts-a4a45af197578fbe06e6d81f4c479776d732272b.tar.gz
Scripts-a4a45af197578fbe06e6d81f4c479776d732272b.tar.bz2
Scripts-a4a45af197578fbe06e6d81f4c479776d732272b.zip
Fixes for 2011-03-13
-rwxr-xr-xbldins2
-rw-r--r--functions2
-rwxr-xr-xgitprompt5
-rwxr-xr-xmplayer11
-rwxr-xr-xtagit2
-rwxr-xr-xtux2
-rwxr-xr-xwsync16
7 files changed, 31 insertions, 9 deletions
diff --git a/bldins b/bldins
index 4cb846d..fd54bc3 100755
--- a/bldins
+++ b/bldins
@@ -34,7 +34,7 @@ LOGFILE="$HOME/logs/kbuild/kbuild-$(date +%s)"
export KCFLAGS=" -march=native -O2 -pipe "
#export LDFLAGS_MODULE="-s"
#export KBUILD_LDFLAGS_MODULE="-s"
-export INSTALL_MOD_STRIP="-s"
+#export INSTALL_MOD_STRIP="-s"
if [[ $install == 0 ]];then
diff --git a/functions b/functions
index 067019a..d5510da 100644
--- a/functions
+++ b/functions
@@ -23,7 +23,7 @@ $HOME/bin/mplayer "$@"
function etym(){
word="$@"
-/usr/bin/w3m "http://www.etymonline.com/index.php?search=$word&searchmode=none"
+/usr/bin/w3m -dump "http://www.etymonline.com/index.php?search=$word&searchmode=none"
}
function getmovie (){
diff --git a/gitprompt b/gitprompt
index fd484ee..ec44783 100755
--- a/gitprompt
+++ b/gitprompt
@@ -4,8 +4,9 @@
trap 'print -n;exit 1' INT
autoload -U colors && colors
#isgit="$(git rev-parse --is-inside-work-tree 2>/dev/null)"
-#isgit="$(git rev-parse --is-inside-work-tree 2>/dev/null)"
-if test (../)#.git(N) 2>/dev/null;then
+isgit="$(git rev-parse --is-inside-work-tree 2>/dev/null)"
+#if test (../)#.git(N) 2>/dev/null;then
+if [[ $isgit == "true" ]];then
local gprompt="("
gprompt+="$(git branch | grep '*'| cut -d ' ' -f 2 | tr -d '\n')"
#timeout 3 git status -s
diff --git a/mplayer b/mplayer
index 5ad4082..6c829e9 100755
--- a/mplayer
+++ b/mplayer
@@ -4,6 +4,7 @@ AUX_INVO=0
POSITION=0
maxplayers=1
network=0
+stdin=0
firstime=0
randnum=$((${RANDOM}%${maxplayers}))
mkdir -p /tmp/mplayer
@@ -56,6 +57,10 @@ if [[ -z "$1" ]];then
fi
else
+ if [[ $1 == "-" ]];then
+ stdin=1
+ return
+ fi
if isurl "$(tr -d '.' <<< $1)";then # Fix /a/b/c/d type
FILE="$1"
network=1
@@ -175,7 +180,11 @@ preplay
[[ $firstime == 1 ]] && sleep 3
-pecho "loadfile \"$FILE\" 2" /tmp/mplayer.fif
+if [[ $stdin == 1 ]];then
+ pecho "loadfile -" /tmp/mplayer.fif
+else
+ pecho "loadfile \"$FILE\" 2" /tmp/mplayer.fif
+fi
check_status
diff --git a/tagit b/tagit
index 1db2085..754b1c3 100755
--- a/tagit
+++ b/tagit
@@ -1,6 +1,6 @@
#!/bin/zsh
-pushd $HOME/Arch/vim/tags
+pushd $HOME/.vim/tags
typeset -A paths
paths=(python /usr/lib/python2.7/ perl /usr/share/perl5 c /usr/include vim /usr/share/vim )
diff --git a/tux b/tux
index 0fdf7f6..ac35d47 100755
--- a/tux
+++ b/tux
@@ -12,7 +12,7 @@ if [[ $arg == "tnum" ]];then
setopt nonomatch
if ! tmux list-windows -t $session | /bin/grep -i $app | grep -v grep &>/dev/null;then
lastone=$(( $(tmux list-windows -t $session | tail -1 | awk -F: '{ print $1 }') + 1 ))
- PATH="/usr/local/bin:/bin:/usr/bin:/sbin:/usr/sbin:/home/raghavendra/bin"
+ PATH="/usr/local/bin:/bin:/usr/bin:/sbin:/usr/sbin:/home/raghavendra/bin:/home/raghavendra/bin/libexec"
if [[ ! -f =$app ]];then
tmux new-window -d -t $session:$lastone =$muxaliases[$app]
else
diff --git a/wsync b/wsync
index a5a693d..766b1bf 100755
--- a/wsync
+++ b/wsync
@@ -1,15 +1,27 @@
#!/bin/zsh
+pread (){
+ echo "$@"
+ echo
+ echo -n ">_ "
+ read
+ }
projdir="/home/raghavendra/Arch/Projects"
remotedir="/sate/gitole"
for proj in $projdir/*
do
- echo "Syncing $proj"
+ pread "Syncing $proj"
pushd $proj
+ if /bin/grep -q "Unnamed repo" .git/description;then
+ echo "Enter one line description"
+ >| .git/description
+ fi
if [[ ! -d $remotedir/$proj:t ]];then
- git clone --mirror -v $remotedir/$proj:t
+ #git clone --mirror -v $proj $remotedir/$proj:t
+ scp -q -r $proj sate@wnohang.net:/$remotedir:t/
else
git push --mirror -v $remotedir/$proj:t
fi
popd
+ echo "$proj done"
done