安装酸奶问题

时间:2015-01-13 07:15:38

标签: node.js npm yeoman yeoman-generator yo

我正在尝试从Mac的命令行安装yeogurt生成器。现在问题是它已成功安装,但是当我执行任何 yo命令时找不到命令。

下面是我的安装日志和我的.bash_profile和.bashrc文件

安装日志

MacBook-Pro:~ administrator$ sudo npm install -g generator-yeogurt
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/bower-registry-client/node_modules/bower-config requires osenv@'0.0.3' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/osenv,
npm WARN unmet dependency which is version 0.1.0
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/inquirer/node_modules/readline2 requires lodash@'~2.4.1' but will load
npm WARN unmet dependency undefined,
npm WARN unmet dependency which is version undefined
npm WARN unmet dependency /usr/local/lib/node_modules/grunt/node_modules/grunt-legacy-util requires lodash@'~0.9.2' but will load
npm WARN unmet dependency undefined,
npm WARN unmet dependency which is version undefined
npm WARN unmet dependency /usr/local/lib/node_modules/grunt/node_modules/grunt-legacy-util requires underscore.string@'~2.2.1' but will load
npm WARN unmet dependency undefined,
npm WARN unmet dependency which is version undefined
npm WARN unmet dependency /usr/local/lib/node_modules/grunt/node_modules/findup-sync/node_modules/glob requires minimatch@'0.3' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/grunt/node_modules/minimatch,
npm WARN unmet dependency which is version 0.2.14
npm WARN unmet dependency /usr/local/lib/node_modules/grunt/node_modules/js-yaml/node_modules/argparse requires underscore.string@'~2.4.0' but will load
npm WARN unmet dependency undefined,
npm WARN unmet dependency which is version undefined
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-contrib-qunit/node_modules/grunt-lib-phantomjs/node_modules/phantomjs/node_modules/npmconf requires mkdirp@'^0.5.0' but will load
npm WARN unmet dependency undefined,
npm WARN unmet dependency which is version undefined
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-contrib-qunit/node_modules/grunt-lib-phantomjs/node_modules/phantomjs/node_modules/npmconf requires semver@'2 || 3 || 4' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-contrib-qunit/node_modules/grunt-lib-phantomjs/node_modules/semver,
npm WARN unmet dependency which is version 1.0.14
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-init/node_modules/prompt requires async@'0.1.x' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-init/node_modules/async,
npm WARN unmet dependency which is version 0.2.10
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-init/node_modules/grunt/node_modules/findup-sync requires lodash@'~2.4.1' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-init/node_modules/grunt/node_modules/lodash,
npm WARN unmet dependency which is version 0.9.2
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-init/node_modules/grunt/node_modules/findup-sync/node_modules/glob requires minimatch@'0.3' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/grunt-init/node_modules/grunt/node_modules/minimatch,
npm WARN unmet dependency which is version 0.2.14
generator-yeogurt@0.13.5 /usr/local/lib/node_modules/generator-yeogurt
├── colors@0.6.2
├── rimraf@2.2.8
├── lodash@2.4.1
└── yeoman-generator@0.17.7 (dargs@2.1.0, diff@1.2.1, class-extend@0.1.1, text-table@0.2.0, underscore.string@2.4.0, mime@1.2.11, async@0.9.0, debug@1.0.4, nopt@3.0.1, isbinaryfile@2.0.3, grouped-queue@0.3.0, cross-spawn@0.2.3, run-async@0.1.0, chalk@0.5.1, shelljs@0.3.0, mkdirp@0.5.0, iconv-lite@0.4.6, glob@4.3.3, findup-sync@0.1.3, github-username@1.1.1, file-utils@0.2.1, request@2.51.0, gruntfile-editor@0.2.0, cheerio@0.17.0, download@1.0.7, inquirer@0.7.3)
MacBook-Pro:~ administrator$ yo
-bash: yo: command not found
MacBook-Pro:~ administrator$ 

的.bash_profile

export PATH=$PATH:/Users/administrator/Downloads/ChromeDownloads/adt-bundle-mac-x86_64-20140702_2/sdk/platform-tools
$ export PATH=${PATH}:/Applications/Momentics.app/host_10_2_0_15/darwin/x86/usr/bin/
export PATH="$PATH":~/.node/bin
export PATH="/usr/local/bin:$PATH"

export SENCHA_SDK_TOOLS_2_0_0_BETA3="/Applications/SenchaSDKTools-2.0.0-beta3"

# New environment setting added by BB10 WebWorks SDK on Sat Mar 01 12:33:46 GMT+05:30 2014 1.
# The unmodified version of this file is saved in /Users/administrator/.bash_profile1186019250.
# Do NOT modify these lines; they are used to uninstall.
WEBWORKS_HOME="/Applications/BlackBerry/BB10 WebWorks SDK 2.0.0.54"
export WEBWORKS_HOME
# End comments by InstallAnywhere on Sat Mar 01 12:33:46 GMT+05:30 2014 1.

# New environment setting added by BB10 WebWorks SDK on Sat Mar 01 12:33:46 GMT+05:30 2014 2.
# The unmodified version of this file is saved in /Users/administrator/.bash_profile1186019250.
# Do NOT modify these lines; they are used to uninstall.
PATH="$WEBWORKS_HOME:${PATH}"
export PATH
# End comments by InstallAnywhere on Sat Mar 01 12:33:46 GMT+05:30 2014 2.

# New environment setting added by BB10 WebWorks SDK 2.1.0.13 on Fri Jun 27 21:20:23 GMT+05:30 2014 1.
# The unmodified version of this file is saved in /Users/administrator/.bash_profile780247064.
# Do NOT modify these lines; they are used to uninstall.
WEBWORKS_HOME="/Applications/BB10 WebWorks SDK 2.1.0.13"
export WEBWORKS_HOME
# End comments by InstallAnywhere on Fri Jun 27 21:20:23 GMT+05:30 2014 1.

# New environment setting added by BB10 WebWorks SDK 2.1.0.13 on Fri Jun 27 21:20:23 GMT+05:30 2014 2.
# The unmodified version of this file is saved in /Users/administrator/.bash_profile780247064.
# Do NOT modify these lines; they are used to uninstall.
PATH="$WEBWORKS_HOME:$WEBWORKS_HOME/cordova-blackberry/bin/dependencies/bb-tools/bin:${PATH}"
export PATH
# End comments by InstallAnywhere on Fri Jun 27 21:20:23 GMT+05:30 2014 2.

export PATH="$PATH":/Users/administrator/.node/bin

,这是我的.bashrc

export PATH=/Applications/SenchaSDKTools-2.0.0-beta3:$PATH




export SENCHA_SDK_TOOLS_2_0_0_BETA3="/Applications/SenchaSDKTools-2.0.0-beta3"

这个Yeogurt确实出现在node_modules文件夹中。但我仍然无法使用 yo命令

enter image description here

我需要解决这个问题。

谢谢, Ankit Tanna

1 个答案:

答案 0 :(得分:1)

你没有安装yeoman:

sudo npm install -g yo
相关问题