Ubuntuでログインしても.bash_profileが読み込まれない

Ubuntuはインストール直後の設定では,グラフィカルログイン(普通にパソコンを立ち上げてログインすること)したときに,設定ファイル~/profileは読み込まれるのに~/.bash_profileは読み込まれません./etc/gdm/Xsessionファイルを以下のように修正します.
・・・
# First read /etc/profile and .profile
test -f /etc/profile && . /etc/profile
test -f "$HOME/.profile" && . "$HOME/.profile"
test -f "$HOME/.bash_profile" && . "$HOME/.bash_profile"
# Second read /etc/xprofile and .xprofile for X specific setup
test -f /etc/xprofile && . /etc/xprofile
test -f "$HOME/.xprofile" && . "$HOME/.xprofile"
・・・
赤文字の4行目を追加しています.(このブログの)表示の都合で2行になっているかもしれませんが,1行にまとめて書きましょう.「&&」やその後の「.」の前後には空白が一つずつ入ります.

コメント

No title

~/.bash_profile使わずに~/.bashrc使えばいいかと。

コメントの投稿

管理者にだけ表示を許可する

trackback


この記事にトラックバックする(FC2ブログユーザー)

オススメ商品