Homebrewのパスを通すということをしたいのですが、よくわからないので質問させていただきます。
具体的には
vim ~/.bash_profile
このコマンドで.bash_prifileファイルを開き、そのうえで、
export PATH=/usr/local/bin:$PATH
ファイルに以下のコードを書き、保存
ということがしたいです。
mac10.14.1でterminalにvim ~/.bash_profileと入力しenterすると
Swap file "~/.bash_profile.swp" already exists! [O]pen Read-Only, (E)dit anyway, (R)ecover, (D)elete it, (Q)uit, (A)bort`
という表示がでてきてしまいます。
Enterを押してみると、
# Setting PATH for Python 3.7 # The original version is saved in .bash_profile.pysave PATH="/Library/Frameworks/Python.framework/Versions/3.7/bin:${PATH}" export PATH # added by Anaconda3 2018.12 installer # >>> conda init >>> # !! Contents within this block are managed by 'conda init' !! __conda_setup="$(CONDA_REPORT_ERRORS=false '/anaconda3/bin/conda' shell.bash hook 2> /dev/null)" if [ $? -eq 0 ]; then \eval "$__conda_setup" else if [ -f "/anaconda3/etc/profile.d/conda.sh" ]; then . "/anaconda3/etc/profile.d/conda.sh" CONDA_CHANGEPS1=false conda activate base else \export PATH="/anaconda3/bin:$PATH" fi fi unset __conda_setup # <<< conda init <<< ~ "~/.bash_profile" [readonly] 21L, 698C
というのがでてきます。
ファイルに書き込むというのがよくわからなかったので、先頭に
export PATH=/usr/local/bin:$PATH
を書き込んだのですが、保存とかがなかったので、そのまま左上の赤い丸を押して終了させました。
これで、pathを通せているのかわかりません。
一応pathを調べる方法でecho $PATHがあり、実行すると
スラッシュで区切られた羅列の中に、
/usr/local/bin:/
というのがあったので、pathを通せているのでしょうか。
お分かりの方がいらしたら教えていただけると幸いです。
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/04/26 12:51
2019/04/27 00:56