2011-06-25 17:37:31 +00:00
|
|
|
|
2011-06-25 20:23:38 +00:00
|
|
|
# PS1="\[\e]0;\@ [\u@\h] [\w]\007\]\[\e[1;33m\]\@ \[\e[1;37m\][\[\e[1;35m\]\u\[\e[1;37m\]@\[\e[1;32m\]\h\[\e[1;37m\]] \[\e[1;37m\][\[\e[1;31m\]\w\[\e[1;37m\]] [\[\e[1;36m\]$(ls -l | grep "^-" | wc -l | tr -d " ") \[\e[1;34m\]files\[\e[1;37m\]] \n\[\e[1;33m\]\@ \[\e[1;37m\]$ \[\e[0m\]"
|
2011-06-25 17:37:31 +00:00
|
|
|
|
2011-11-22 02:32:50 +00:00
|
|
|
export SHELL=/bin/bash
|
|
|
|
|
2011-06-26 16:00:26 +00:00
|
|
|
set_prompt() {
|
2011-06-25 20:23:38 +00:00
|
|
|
local BLUE="\[\e[0;34m\]"
|
|
|
|
local DARK_BLUE="\[\e[1;34m\]"
|
|
|
|
local RED="\[\e[0;31m\]"
|
|
|
|
local DARK_RED="\[\e[1;31m\]"
|
|
|
|
local GREEN="\[\e[0;32m\]"
|
|
|
|
local NO_COLOR="\[\e[0m\]"
|
|
|
|
|
|
|
|
case $TERM in
|
|
|
|
xterm*|screen)
|
|
|
|
TITLEBAR='\[\e]0;\u@\h \w\007\]';
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
TITLEBAR="";
|
|
|
|
;;
|
|
|
|
esac
|
2011-06-25 17:37:31 +00:00
|
|
|
|
|
|
|
FAILURE_COLOR="if [[ \$? = '0' ]]; then echo \"$GREEN\"; else echo \"$RED\"; fi"
|
|
|
|
|
2011-06-26 01:55:40 +00:00
|
|
|
PS1="${TITLEBAR}$BLUE[\t]\`$FAILURE_COLOR\` \u@\h> $NO_COLOR"
|
2011-06-25 17:37:31 +00:00
|
|
|
}
|
|
|
|
|
2011-11-22 02:26:43 +00:00
|
|
|
# sets the PS1 prompt
|
2011-06-26 03:03:37 +00:00
|
|
|
set_prompt
|
2011-06-25 17:37:31 +00:00
|
|
|
|
2011-06-28 00:00:15 +00:00
|
|
|
# makes ls print pretty
|
2012-12-24 19:45:08 +00:00
|
|
|
unamestr=`uname`
|
|
|
|
if [[ "$unamestr" == 'Linux' ]]; then
|
|
|
|
alias ls="ls --color=auto"
|
|
|
|
elif [[ "$unamestr" == 'Darwin' ]]; then
|
|
|
|
alias ls="ls -G"
|
|
|
|
fi
|
2011-06-28 00:00:15 +00:00
|
|
|
|
|
|
|
# default editor
|
|
|
|
export EDITOR=vim
|
|
|
|
|
|
|
|
# set history
|
|
|
|
export HISTSIZE=1000
|
|
|
|
export HISTFILESIZE=1000
|
|
|
|
export HISTCONTROL=ignoredups
|
|
|
|
|
2011-11-22 02:26:43 +00:00
|
|
|
# disable messaging
|
2012-04-21 23:13:09 +00:00
|
|
|
if `tty -s`; then
|
|
|
|
mesg n
|
|
|
|
fi
|
2011-11-22 02:26:43 +00:00
|
|
|
|
2012-01-22 00:06:19 +00:00
|
|
|
# set the path for Hadoop
|
2012-06-18 17:30:17 +00:00
|
|
|
# export HADOOP_VERSION=hadoop-1.0.1
|
|
|
|
# export HADOOP=~/hadoop/$HADOOP_VERSION
|
|
|
|
# export PATH=$PATH:$HADOOP/bin
|
2012-04-21 23:13:09 +00:00
|
|
|
export JAVA_HOME=/usr
|
2012-01-23 20:39:55 +00:00
|
|
|
|
2011-12-16 19:33:07 +00:00
|
|
|
# add the rubygem location
|
2013-04-03 03:51:53 +00:00
|
|
|
#export PATH=$PATH:/var/lib/gems/1.8/bin/
|
|
|
|
#export PATH=~/.rbenv/bin:~/.rbenv/shims:$PATH
|
2012-07-25 14:32:57 +00:00
|
|
|
##
|
|
|
|
# Your previous /Users/nicholas/.profile file was backed up as /Users/nicholas/.profile.macports-saved_2012-06-19_at_15:40:04
|
|
|
|
##
|
|
|
|
|
|
|
|
# MacPorts Installer addition on 2012-06-19_at_15:40:04: adding an appropriate PATH variable for use with MacPorts.
|
|
|
|
export PATH=/opt/local/bin:/opt/local/sbin:$PATH
|
|
|
|
# Finished adapting your PATH environment variable for use with MacPorts.
|
2014-09-26 03:17:00 +00:00
|
|
|
#export JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home/
|
|
|
|
export JAVA_HOME="$(/usr/libexec/java_home)"
|
2012-07-25 14:32:57 +00:00
|
|
|
|
2013-04-03 03:51:53 +00:00
|
|
|
#### ALIAS SECTION
|
|
|
|
|
|
|
|
# servers
|
|
|
|
alias sshneptune="ssh ntietz@neptune.cs.kent.edu"
|
|
|
|
alias sshposeidon="ssh ntietz@poseidon.cs.kent.edu"
|
|
|
|
alias sshntietz="ssh nicholas@ntietz.com"
|
|
|
|
alias sshacm="ssh ntietz@acm.cs.kent.edu"
|
|
|
|
|
|
|
|
# commands
|
|
|
|
alias cls='clear && ls'
|
|
|
|
alias doit='sudo $(history -p !-1)'
|
2013-04-04 04:20:56 +00:00
|
|
|
alias f="pushd"
|
|
|
|
alias b="popd"
|
2014-09-26 03:17:00 +00:00
|
|
|
alias psql="'/Applications/Postgres.app/Contents/Versions/9.3/bin'/psql -p5432"
|
2012-07-25 14:32:57 +00:00
|
|
|
|
2013-05-10 20:51:56 +00:00
|
|
|
macos_magic_fix() {
|
|
|
|
killall Dock
|
|
|
|
}
|
|
|
|
|
2013-06-06 21:36:06 +00:00
|
|
|
export PATH=$PATH:~/.bin
|
|
|
|
|
2014-09-26 03:17:00 +00:00
|
|
|
export HISTCONTROL=ignorespace
|
2013-06-06 21:36:06 +00:00
|
|
|
|