Skip to content

Instantly share code, notes, and snippets.

@jarun
Last active April 29, 2017 09:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jarun/8395bc6fb46e2a4df313 to your computer and use it in GitHub Desktop.
Save jarun/8395bc6fb46e2a4df313 to your computer and use it in GitHub Desktop.
fish_prompt.fish
alias l='ls'
alias lh='ll -h'
alias ll='ls -l'
#alias mic='amixer set Capture toggle'
alias hi='history'
alias au='sudo apt update'
alias make='colormake'
alias mv='mv -i'
alias pe='patool extract'
alias man='man -a'
alias note='vi ~/Dropbox/Public/Docs/Notes/note'
alias top='top -c'
alias aria='aria2c -x 5'
alias mc='make clean'
alias mm='make clean;make'
alias mi='make clean;make; sudo make install'
alias weather='curl wttr.in/bangalore'
alias plint='python3 -m flake8'
alias wcalc='wcalc -EE'
alias gd='git diff'
alias avgo='curl -s "http://download.finance.yahoo.com/d/quotes.csv?s=avgo&f=l1c1"'
alias yt='youtube-dl'
alias n='nnn -d'
export VISUAL=vim
export EDITOR="$VISUAL"
export NNN_DE_FILE_MANAGER=thunar
export NNN_FALLBACK_OPENER=xdg-open
export NNN_COPIER="/usr/local/bin/copier.sh"
set fish_greeting ""
alias mpv="mpv --no-border --geometry=50%:50% --autofit-larger=50%x50% --no-config --no-fs --hwdec=auto --sub-auto=fuzzy --vo=opengl-hq, --ao=alsa, --stop-screensaver --cursor-autohide=no --no-keepaspect --monitorpixelaspect=1 --osd-scale=1 --sub-ass --embeddedfonts --ass-line-spacing=0 --sub-scale=1 --sub-text-font=\"Noto Sans\" --sub-text-color=#ffffff00 --sub-text-shadow-color=#ff000000 --sub-text-border-color=#ff000000 --sub-text-border-size=1.25 --sub-text-shadow-offset=1.25 --sub-text-font-size=45 --sub-text-bold=no --sub-codepage=ISO-8859-1 --sub-pos=100 --volume=100 --cache=4096 --osd-level=0 --audio-channels=2 --audio-pitch-correction=yes --softvol=yes --softvol-max=110 --load-scripts=yes"
# Google
alias g='googler --noua -c in -n 8'
# Amazon
alias buy='g -w amazon.in'
# Google News
alias news='g -n 7 -l en -N'
# TuxDiary
alias t='g -w tuxdiary.com'
# Words
alias def='g -n 3 -l en define'
# IMDB
alias @imdb='g -w imdb.com'
function ls --description 'List contents of directory'
set -l param --color=auto
if isatty 1
set param $param --indicator-style=classify --group-directories-first
end
command ls $param $argv
end
function ta --description 'Generate ctags and cscope files'
rm -rf tags
rm -rf cscope.files
rm -rf cscope.out
find $PWD | egrep -i '\.(c|h|cpp)$' > cscope.files
ctags -R . *.c *.h *.cpp --tag-relative=yes ./
end
export NNN_TMPFILE="/tmp/nnn"
function n --description 'support nnn quit and change directory'
nnn -d $argv[1]
if test -e $NNN_TMPFILE
. $NNN_TMPFILE
rm $NNN_TMPFILE
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment