dotfiles

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit fdfd8f33a157b889f975b7d00b0a6238705253bd
parent 5df82388e23d6d22ab37740be26612cd7d18d61e
Author: Yuval Langer <yuval.langer@gmail.com>
Date:   Mon, 10 Oct 2016 14:34:55 +0300

Update bash files

Diffstat:
Mbash/bash_aliases | 26++++++++++++++++++++++++++
Mbash/bashrc | 29+++++++++++++++++++++++------
2 files changed, 49 insertions(+), 6 deletions(-)

diff --git a/bash/bash_aliases b/bash/bash_aliases @@ -1,3 +1,5 @@ +#!/bin/bash + # enable color support of ls and also add handy aliases if [ -x /usr/bin/dircolors ]; then test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" @@ -24,3 +26,27 @@ alias gl='g l' alias gs='g s' alias gc='g c' alias gd='g d' + +alias ec="emacsclient" + +alias hebdate="hdate --hebrew|cut -f 3 -d ','|grep -v '^$'" +alias emptify="truncate -c -s 0" + +pip3ls () { + pip3 freeze --user | sed 's#==.*##' +} +alias pip3i="pip3 install --user --upgrade" +pip3up () { + pip3i `pip3ls` +} +alias pip3un="pip3 uninstall" + +# http://cs-syd.eu/posts/2015-06-21-gtd-with-taskwarrior-part-2-collection.html +alias in='task add +in' +tickle () { + deadline="$1" + shift + in +tickle wait:"$deadline" $@ +} +alias tick=tickle +alias think='tickle +1d' diff --git a/bash/bashrc b/bash/bashrc @@ -1,3 +1,5 @@ +#!/bin/bash + # ~/.bashrc: executed by bash(1) for non-login shells. # see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) # for examples @@ -31,9 +33,7 @@ shopt -s checkwinsize [ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" # set variable identifying the chroot you work in (used in the prompt below) -if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then - debian_chroot=$(cat /etc/debian_chroot) -fi +[ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ] && debian_chroot="$(cat /etc/debian_chroot)" # set a fancy prompt (non-color, unless we know we "want" color) case "$TERM" in @@ -94,15 +94,20 @@ alias l='ls -CF' # Add an "alert" alias for long running commands. Use like so: # sleep 10; alert -alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"' +alias alert='notify-send --urgency=low -i "$( [ $? = 0 ] && echo terminal || echo error ; )" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"' # Alias definitions. # You may want to put all your additions into a separate file like # ~/.bash_aliases, instead of adding them here directly. # See /usr/share/doc/bash-doc/examples in the bash-doc package. -if [ -f ~/.bash_aliases ]; then - . ~/.bash_aliases +[ -f ~/.bash_aliases ] && . ~/.bash_aliases + +PYTHONPATH="$HOME/.local/lib/python3.5/dist-packages:$PYTHONPATH" + +if [ -d "$HOME/gopath" ] ; then + GOPATH="$HOME/gopath" + PATH="$GOPATH/bin:$PATH" fi # enable programmable completion features (you don't need to enable @@ -116,3 +121,15 @@ if ! shopt -oq posix; then fi fi [ -r ~/.byobu/prompt ] && . ~/.byobu/prompt #byobu-prompt# + +VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3 +. ~/.local/bin/virtualenvwrapper_lazy.sh +#. ~/.local/lib/python3.5/site-packages/pyvenvwrapper/pyvenvwrapper_settings +#source ~/.local/lib/python3.5/site-packages/pyvenvwrapper/pyvenvwrapper + +export PYTHONPATH +export GOPATH +export PATH + +# http://cs-syd.eu/posts/2015-06-21-gtd-with-taskwarrior-part-2-collection.html +export PS1='$(task +in +PENDING count)i$(task count)t '$PS1