変数に関するメモ。 💤がついてるのはzsh 固有のもの。
- シェル変数 → 子プロセスに継承されない
- 環境変数 → 子プロセスに継承される
環境変数登録
| // | |
| // Swift UnsafePointer converter | |
| // Kaz Yoshikawa | |
| // | |
| // These code demonstrates how to convert swift pointers to the other forms of pointers. | |
| // | |
| // Source: | |
| // Swift の Array やら ArraySlice やらポインタの変換まとめ | |
| // https://qiita.com/Satachito/items/4c39c9b06304e4d86660 | |
| // |
| class Number /* class cluser */ { | |
| class Int8: Number { | |
| var value: Swift.Int8 | |
| init(_ value: Swift.Int8) { self.value = value } | |
| } | |
| class Int: Number { | |
| var value: Swift.Int | |
| init(_ value: Swift.Int) { self.value = value } | |
| } |
Application > Terminalを起動したとき,環境変数の追加その他もろもろを自動でやってほしいとき,.bashrcを編集すればよい.
初期状態では,ホームディレクトリに.bashrcファイルはないので,自分で作成する.
cd ~
vi .bashrc例えばPATHに何かを追加したいときは,以下を足して保存.