-
Notifications
You must be signed in to change notification settings - Fork 0
/
.bash_profile
50 lines (41 loc) · 1.48 KB
/
.bash_profile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# BASH PROFILE
# source functions
source $HOME/.dotfiles/.shfunctions.zsh
# set prompt
PS1='\[\033[01;34m\](bash) \w> \[\033[00m\]'
# set paths
export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-14.0.2.jdk/Contents/Home
export PATH="/Library/Frameworks/Python.framework/Versions/3.8/bin:${PATH}"
export PATH="$PATH:/usr/local/smlnj/bin"
export PATH="$HOME/.cargo/bin:$PATH"
export PATH="$PATH:$HOME/.opt/bin"
# set environment variables
export PYTHONDONTWRITEBYTECODE=1
export BASH_SILENCE_DEPRECATION_WARNING=1
# safe environment
set -o noclobber
alias rm='rm -i' # Prompt before removing files via 'rm'
alias cp='cp -i' # Prompt before overwriting files via 'cp'
alias mv='mv -i' # Prompt before overwriting files via 'mv'
alias ln='ln -i' # Prompt before overwriting files via 'ln'
# navigation shortcuts
alias ,="cd -"
alias ..='cd ..'
alias ...='cd ../..'
alias ....='cd ../../..'
cs=~/Dropbox/cs # any trouble with alias and var having same name?
alias cs="cd ~/Dropbox/cs"
alias dotfiles="cd ~/.dotfiles"
# command aliases
alias python="python3"
alias l='ls -lahG'
alias ls='ls -G'
alias grep='ggrep --color=auto' # GNU grep as default
alias less='less -m'
# application shortcuts
alias chrome='open -a Google\ Chrome'
alias finder='open -a Finder'
# history tweaks
shopt -s histappend # on shell exit, append instead of overwrite
export HISTCONTROL=erasedups:ignoredups # ignore duplicate command lines.
export HISTTIMEFORMAT="%F %T " # show dates and times.