Skip to content

Instantly share code, notes, and snippets.

@judofyr
Created March 4, 2011 17:02
Show Gist options
  • Save judofyr/855101 to your computer and use it in GitHub Desktop.
Save judofyr/855101 to your computer and use it in GitHub Desktop.
function mvim() {
if [ -d "$1" ]; then
local dir=$(printf %q "$1")
command mvim --cmd ":cd $dir" "$@"
else
command mvim "$@"
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment