Created
October 19, 2010 14:05
-
-
Save dmukhg/634244 to your computer and use it in GitHub Desktop.
.*shrc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ===================== Mark functions ======================= | |
# calling mark, sets up a file ~/.mark_dir containing | |
# the value of the current directory | |
# hence forth, any terminal you open will be directed to this | |
# directory | |
function m(){ | |
printf `pwd` > ~/.mark_dir | |
echo 'Directory Marked' | |
} | |
# to turn this off, call unmark or call mark on some other directory | |
# unmark resets mark_dir to the home directory and also places you at ~ | |
function u(){ | |
printf ~ > ~/.mark_dir | |
echo 'Directory Marked Reset to home' | |
cd ~ | |
} | |
read MARKDIR < ~/.mark_dir | |
cd $MARKDIR | |
# ===================== End Mark functions =================== |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment