16
19

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

fishでPATHを通したり消したり

Posted at

よく忘れるので自分用のメモ。

PATHへの追加

fishでPATHを追加しようとする場合、恒久的にPATHを追加しようと思ったら、$fish_user_pathsに追加します。

set -U fish_user_paths /usr/local/bin $fish_user_paths

PATHから削除

PATHから削除する場合は、$fish_user_pathsから値を削除する必要があります。
$fish_user_pathsは配列なので、その値のある項目を消しましょう。
配列の開始は1からになるので、その点に注意しましょう。

set -e -U fish_user_paths[1]
16
19
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
16
19

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?