読者です 読者をやめる 読者になる 読者になる

DRYな備忘録

Don't Repeat Yourself.

bower installが失敗する: Object #<Object> has no method 'tmpdir'

問題

% bower install

/Users/otiai10/.nvm/v0.8.11/lib/node_modules/bower/node_modules/tmp/lib/tmp.js:266
    throw err;
          ^
TypeError: Object #<Object> has no method 'tmpdir'

#以下略

原因

  • nodejs古い

解決

% nvm ls

   v0.8.11
current:        v0.8.11
default -> v0.8.11
% nvm install 0.10
######################################################################## 100.0%
Now using node v0.10.26
% nvm use 0.10
Now using node v0.10.26
% npm install -g bower
% which bower
/Users/otiai10/.nvm/v0.10.26/bin/bower
% bower install
[?] May bower anonymously report usage statistics to improve the tool over time? No
-----------------------------------------
Update available: 1.3.1 (current: 1.2.8)
Run npm update -g bower to update
-----------------------------------------

bower showv#*                   cached git@github.com:otiai10/showv.git#fa6f98e68e
bower showv#*                 validate fa6f98e68e against git@github.com:otiai10/showv.git#*
bower jquery#1.10.1             cached git://github.com/jquery/jquery.git#1.10.1
bower jquery#1.10.1           validate 1.10.1 against git://github.com/jquery/jquery.git#1.10.1
bower handlebars#1.0.0          cached git://github.com/components/handlebars.js.git#1.0.0
bower handlebars#1.0.0        validate 1.0.0 against git://github.com/components/handlebars.js.git#1.0.0
bower handlebars#1.0.0         install handlebars#1.0.0
bower jquery#1.10.1            install jquery#1.10.1
bower showv#*                  install showv#fa6f98e68e

handlebars#1.0.0 bower_components/handlebars

jquery#1.10.1 bower_components/jquery

showv#fa6f98e68e bower_components/showv

動いた

参考

これかな

DRYな備忘録