Last active
August 25, 2017 14:38
-
-
Save zimme/e68f2392e9ad4f2f154dc081571c3d26 to your computer and use it in GitHub Desktop.
Meteor related fish shell functions
This file contains hidden or 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
# This will create an alias function for meteor | |
# if Meteor is installed. | |
# The alias will allow you to run meteor from | |
# a git checkout by using the --git flag | |
# Note: You need to have a Meteor git checkout | |
# in ~/Development/meteor or where ever you set | |
# the path to. | |
if test -e /usr/local/bin/meteor | |
function meteor | |
if count $argv > /dev/null | |
for i in (seq (count $argv)) | |
if test x"$argv[$i]" = x'--git' -a -d ~/Development/meteor | |
set -e argv[$i] | |
~/Development/meteor/meteor $argv | |
return $status | |
end | |
end | |
end | |
eval (which meteor) $argv | |
end | |
end |
This file contains hidden or 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
# This will create an alias function for npm | |
# if Meteor is installed. | |
# The alias will call meteor npm instead of npm | |
# if we're inside a Meteor project root directory | |
if test -e /usr/local/bin/meteor | |
function npm | |
if test -e .meteor/release | |
eval (which meteor) npm $argv | |
else | |
eval (which npm) $argv | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment