[英]Missing proper which command. Make sure it is installed before using RVM
我想我在Mac中安裝了Magnet並刪除了更好的觸摸工具,然后我的終端突然得到了:
Last login: Tue Aug 15 16:23:47 on ttys000
ERROR: Missing proper 'which' command. Make sure it is installed before using RVM!
WARNING:
Errors sourcing '/Users/kenpeter/.rvm/scripts/base'.
RVM will likely not work as expected.
ERROR: Missing proper 'which' command. Make sure it is installed before using RVM!
WARNING:
Errors sourcing '/Users/kenpeter/.rvm/scripts/base'.
RVM will likely not work as expected.
當我在終端中鍵入時,它可以工作。
我的問題是,如何擺脫這個警告?
我做了yarn global install xxxx
。 它導致rvm抱怨。
yarn global remove xxxx
解決該問題。
參考:
我也收到了
Missing proper which command. Make sure it is installed before using RVM
啟動外殼程序時出現問題。
我用nvm
, avn
和rvm
並有grunt-cli
, karma-cli
, typescript
及typings
通過全球的裝機量yarn
,當我開始得到錯誤。 刪除所有全局軟件包后,錯誤消失了。
現在,我無法重現該問題,請確定。 我以為我願意和別人分享類似的問題。
同樣的問題,但是我終於通過重新安裝RVM使其工作了 。
我為此嘗試發布在問題中的解決方案沒有太多運氣:
https://github.com/rvm/rvm/issues/2385
https://github.com/rvm/rvm/issues/4378
也不能通過Homebrew (重新)安裝RVM。 我使用的是macOS High Sierra 10.13.4(17E199)。 這是我的筆記:
# uninstalling RVM: https://stackoverflow.com/a/4747195/539149
rvm implode
# then delete all mentions of RVM in ~/.bashrc ~/.bash_profile ~/.profile ~/.zshrc
# installing RVM: http://usabilityetc.com/articles/ruby-on-mac-os-x-with-rvm/ https://rvm.io/rvm/install
gpg --keyserver hkp://pgp.mit.edu --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
brew tap --repair
curl -sSL https://get.rvm.io | bash -s stable --ruby
# add RVM to bash profile (usually in one of ~/.bashrc ~/.bash_profile ~/.profile ~/.zshrc)
nano ~/.bashrc
###
# Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
export PATH="$PATH:$HOME/.rvm/bin"
# Load RVM into a shell session *as a function*
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
###
# reload shell settings
source ~/.bash_profile
# upgrading RVM: https://rvm.io/rvm/upgrading
rvm get stable
我意識到,如果您正在一個正在進行中的項目中(也許是這樣?),這不是最佳解決方案。 但是我認為始終保留冪等的片段是很有用的,您可以將其應用於補救情況,然后在以后進行優化。
brew install node
為我修復了它,執行\\which
時出現一些節點錯誤。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.