From: Mark Szymanski Date: Tue, 2 Nov 2010 01:05:33 +0000 (-0500) Subject: Added check for vim in newpost too. X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=689afd9b3d28ebe82625a4f191b506cb0dcf7c05;p=common%2Fbash_it.git Added check for vim in newpost too. --- diff --git a/aliases/jekyll.aliases.bash b/aliases/jekyll.aliases.bash index a9fed04..0e1e3e7 100644 --- a/aliases/jekyll.aliases.bash +++ b/aliases/jekyll.aliases.bash @@ -5,10 +5,16 @@ then alias newentry="cd $JEKYLL_LOCAL_ROOT && $EDITOR ." else alias newentry="cd $JEKYLL_LOCAL_ROOT" +fi # Open the _posts/ directory for making a new blog post (seperate from above alias because not everyone uses jekyll for a blog) -alias newpost="cd $JEKYLL_LOCAL_ROOT/_posts && $EDITOR ." +if [ $EDITOR = "vim"] +then + alias newpost="cd $JEKYLL_LOCAL_ROOT/_posts && $EDITOR ." +else + alias newpost="cd $JEKYLL_LOCAL_ROOT" +fi # Build and locally serve the site