2008-12-05 12:04:53 -05:00
|
|
|
#
|
2015-01-05 14:09:25 -05:00
|
|
|
# FreeSWITCH Dev .bashrc
|
2008-12-05 12:04:53 -05:00
|
|
|
#
|
2014-03-21 11:59:38 -04:00
|
|
|
export UNAME=`uname -s`
|
2008-12-05 12:04:53 -05:00
|
|
|
|
|
|
|
if [ "`id -u`" = "0" ]; then
|
2014-03-21 11:59:38 -04:00
|
|
|
if [ "${UNAME}" = "Linux" ]; then
|
|
|
|
export PATH="$PATH:/opt/bin:/usr/local/bin:/usr/local/sbin:/usr/local/freeswitch/bin"
|
|
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/local/lib/pkgconfig
|
|
|
|
fi
|
|
|
|
if [ "${UNAME}" = "SunOS" ]; then
|
|
|
|
export PATH="$PATH:/opt/64/bin:/opt/bin:/usr/local/bin:/usr/local/sbin:/usr/local/freeswitch/bin"
|
|
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/opt/64/lib/pkgconfig:/usr/lib/amd64/pkgconfig:/opt/lib/pkgconfig:/usr/lib/pkgconfig
|
|
|
|
fi
|
|
|
|
if [ "${UNAME}" = "OpenBSD" ]; then
|
|
|
|
export PATH="$PATH:/usr/local/freeswitch/bin"
|
|
|
|
export AUTOCONF_VERSION=2.69
|
|
|
|
export AUTOMAKE_VERSION=1.13
|
|
|
|
export LIBTOOL=/usr/local/bin/libtoolize
|
|
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig:/usr/lib/pkgconfig
|
2014-10-29 10:52:38 -04:00
|
|
|
export PKG_PATH=http://openbsd.mirrors.pair.com/`uname -r`/packages/`machine -a`/
|
2014-03-21 11:59:38 -04:00
|
|
|
fi
|
|
|
|
if [ "${UNAME}" = "NetBSD" ]; then
|
|
|
|
export PATH="$PATH:/usr/local/freeswitch/bin"
|
|
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/lib/pkgconfig:/usr/pkg/lib/pkgconfig
|
2014-10-29 10:52:38 -04:00
|
|
|
export PKG_PATH=http://ftp.netbsd.org/pub/pkgsrc/packages/NetBSD/`uname -m`/`uname -r`/All/
|
2014-03-21 11:59:38 -04:00
|
|
|
fi
|
|
|
|
if [ "${UNAME}" = "FreeBSD" ]; then
|
|
|
|
export PATH="$PATH:/usr/local/freeswitch/bin"
|
|
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/lib/pkgconfig:/usr/pkg/lib/pkgconfig
|
|
|
|
fi
|
|
|
|
if [ "${UNAME}" = "DragonFly" ]; then
|
|
|
|
export PATH="$PATH:/usr/local/freeswitch/bin"
|
|
|
|
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/lib/pkgconfig:/usr/pkg/lib/pkgconfig
|
|
|
|
fi
|
2008-12-05 12:04:53 -05:00
|
|
|
fi
|
|
|
|
|
2015-02-17 11:23:38 -05:00
|
|
|
if [ "${UNAME}" = "Darwin" ]; then
|
|
|
|
if [ -d ~/src/depot_tools ]; then
|
|
|
|
export PATH=$PATH:~/src/depot_tools
|
|
|
|
fi
|
|
|
|
if [ -d "/Applications/Chromium.app" ]; then
|
|
|
|
alias chromium='CHROME_LOG_FILE=chrome.log /Applications/Chromium.app/Contents/MacOS/Chromium --args --enable-usermedia-screen-capturing --usermedia-screen-capturing --enable-logging --v=1 --vmodule=*source*/talk/*=5 2>&1 | tee console.log'
|
|
|
|
fi
|
|
|
|
if [ -d "/Applications/Google Chrome Canary.app" ]; then
|
|
|
|
alias canary='CHROME_LOG_FILE=chrome.log /Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary --args --enable-usermedia-screen-capturing --usermedia-screen-capturing --enable-logging --v=1 --vmodule=*source*/talk/*=5 2>&1 | tee console.log'
|
|
|
|
fi
|
|
|
|
if [ -d "/Applications/Google Chrome.app" ]; then
|
|
|
|
alias chrome='CHROME_LOG_FILE=chrome.log /Applications/Google\ Chrome.app/Concd outtents/MacOS/Google\ Chrome --args --enable-usermedia-screen-capturing --usermedia-screen-capturing --enable-logging --v=1 --vmodule=*source*/talk/*=5 2>&1 | tee console.log'
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2008-12-05 12:04:53 -05:00
|
|
|
if [ ! -f ~/.inputrc ]; then
|
|
|
|
export INPUTRC="/etc/inputrc"
|
|
|
|
fi
|
|
|
|
|
2010-02-01 13:28:08 -05:00
|
|
|
set -o emacs
|
2015-01-05 13:48:40 -05:00
|
|
|
export PROMPT_COMMAND="history -a; history -c; history -r; ${PROMPT_COMMAND}"
|
|
|
|
export HISTSIZE=5000
|
2014-10-28 15:44:02 -04:00
|
|
|
export TERM=xterm-256color
|
2008-12-05 12:04:53 -05:00
|
|
|
export LESSCHARSET="latin1"
|
|
|
|
export LESS="-R"
|
|
|
|
export CHARSET="ISO-8859-1"
|
2009-02-17 13:43:54 -05:00
|
|
|
export PS1='\n\[\033[01;31m\]\u@\h\[\033[01;36m\] [\d \@] \[\033[01;33m\] \w\n\[\033[00m\]<\#>:'
|
2008-12-05 12:04:53 -05:00
|
|
|
export PS2="\[\033[1m\]> \[\033[0m\]"
|
2015-03-24 16:38:51 -04:00
|
|
|
if [ -f ~/.viplease ]; then
|
2015-03-24 16:41:03 -04:00
|
|
|
if [ -f /usr/bin/vim ]; then
|
|
|
|
export VISUAL=vim
|
|
|
|
else
|
|
|
|
export VISUAL=vi
|
|
|
|
fi
|
2015-03-24 16:38:51 -04:00
|
|
|
else
|
|
|
|
export VISUAL=emacs
|
|
|
|
fi
|
2012-02-01 19:37:23 -05:00
|
|
|
export GIT_SSL_NO_VERIFY=true
|
2008-12-05 12:04:53 -05:00
|
|
|
|
|
|
|
umask 022
|
2008-12-09 19:38:47 -05:00
|
|
|
alias e='emacs'
|
2014-02-18 21:49:00 -05:00
|
|
|
alias eamcs='emacs'
|
|
|
|
alias emcas='emacs'
|
|
|
|
alias meacs='emacs'
|
|
|
|
alias mecas='emacs'
|
2010-05-03 14:46:57 -04:00
|
|
|
alias bgit='git commit --author "Brian West <brian@freeswitch.org>"'
|
2015-02-11 12:40:49 -05:00
|
|
|
alias mgit='git commit --author "Mike Jerris <mike@jerris.com>"'
|
2010-05-03 14:46:57 -04:00
|
|
|
alias tgit='git commit --author "Anthony Minessale <anthm@freeswitch.org>"'
|
2008-12-09 19:38:47 -05:00
|
|
|
alias dp='emacs /usr/local/freeswitch/conf/dialplan/default.xml'
|
2014-03-06 11:51:01 -05:00
|
|
|
alias go='/usr/local/freeswitch/bin/freeswitch -nonat'
|
2010-01-13 13:02:42 -05:00
|
|
|
alias fstop='top -p `cat /usr/local/freeswitch/run/freeswitch.pid`'
|
2015-02-19 15:31:39 -05:00
|
|
|
alias fsgcore='gcore `cat /usr/local/freeswitch/run/freeswitch.pid`'
|
2010-01-13 13:02:42 -05:00
|
|
|
alias fsgdb='gdb /usr/local/freeswitch/bin/freeswitch `cat /usr/local/freeswitch/run/freeswitch.pid`'
|
2009-02-13 16:25:35 -05:00
|
|
|
alias fscore='gdb /usr/local/freeswitch/bin/freeswitch `ls -rt core.* | tail -n1`'
|
2009-06-23 19:45:00 -04:00
|
|
|
alias emacs='emacs -nw'
|
2015-02-17 11:23:38 -05:00
|
|
|
|
|
|
|
if [ "${UNAME}" = "Linux" ]; then
|
2015-02-19 15:31:39 -05:00
|
|
|
alias govg='valgrind --tool=memcheck --log-file=vg.log --leak-check=full --leak-resolution=high --show-reachable=yes .libs/freeswitch -vg'
|
2015-02-17 11:23:38 -05:00
|
|
|
alias jitteron='tc qdisc add dev eth0 root handle 1: netem delay 40ms 20ms ; tc qdisc add dev eth0 parent 1:1 pfifo limit 1000'
|
|
|
|
alias jitteroff='tc qdisc del dev eth0 root netem'
|
|
|
|
fi
|
2015-01-05 14:09:25 -05:00
|
|
|
|
|
|
|
# Auto Update the .bashrc if hostname contains freeswitch.org
|
|
|
|
if [[ $(hostname) =~ "freeswitch.org" ]]; then
|
|
|
|
if [ -f /usr/src/freeswitch.git/support-d/.bashrc ]; then
|
|
|
|
/usr/bin/diff --brief <(sort /usr/src/freeswitch.git/support-d/.bashrc) <(sort ~/.bashrc) >/dev/null
|
|
|
|
if [ $? -eq 1 ]; then
|
|
|
|
/bin/cp -f /usr/src/freeswitch.git/support-d/.bashrc ~/
|
|
|
|
echo ".bashrc updated."
|
|
|
|
source ~/.bashrc
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
# End Auto Update
|
|
|
|
|
2008-12-05 12:04:53 -05:00
|
|
|
# End of file
|