@gorohash posted at 2017-02-07 Revisions Edit Requests Show all likers of this article Show article as Markdown Report articlePROMPTで変数が更新されないZshzshrc More than 1 year has passed since last update. vcs_info の結果が変わらない .zshrc に以下のような PROMPT を設定すると,.zshrc 読み込み時からバージョン管理システムの情報が更新されない. PROMPT="${vcs_info_msg_0_}" シングルクォート使えばOK 上記のようにダブルクォートを使うと, .zshrc の読み込み時に変数が展開されてしまうため,precmd が呼ばれる等で変数の内容が変わっても更新されない. よって,以下のようにシングルクォートを使って変数を展開せずに持っておく. PROMPT='${vcs_info_msg_0_}' 参考 http://qiita.com/cocodrips/items/bb3640a9834c8978d48a TweetToot@gorohash Sign up for free and join this conversation.Sign UpIf you already have a Qiita account log in.