Skip to content

Commit b77e6c5

Browse files
fix: update a0 instructions for MacOS
1 parent b72e859 commit b77e6c5

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

assignment0/README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ Finally, open the command palette (<kbd>Cmd+Shift+P</kbd>), search for `Shell Co
113113
By default, the `g++` command on Mac is an alias to the built-in `clang` compiler. We can fix this by running
114114
115115
```sh
116-
echo 'alias g++="g++-14"' >> ~/.zshrc
116+
echo 'export PATH="$(brew --prefix)/bin:$PATH"\nalias g++="g++-14"' >> ~/.zshrc
117117
```
118118
119119
to make `g++` point to the version of GCC we just installed. Change `g++-14` in the above command to whichever version of GCC was installed.
@@ -124,6 +124,11 @@ Finally, open the command palette (<kbd>Cmd+Shift+P</kbd>), search for `Shell Co
124124
g++ --version
125125
```
126126
127+
> [!NOTE]
128+
> If you are using VSCode to run your code, you may get an issue running this last command. **Make sure you are running a `zsh` terminal inside of VSCode,** as shown in the image below:
129+
> ![An image showing how to change the VSCode terminal to zsh](./docs/mac-zsh.png)
130+
> You will need to do this any time you want to run `g++` for this class. **Alternatively, change VSCode's default terminal to zsh** by pressing <kbd>Cmd+Shift+P</kbd>, going to **Terminal: Select Default Profile**, and selecting **`zsh`**.
131+
127132
### Windows
128133
129134
#### Step One: Installing VSCode

assignment0/docs/mac-zsh.png

65.9 KB
Loading

0 commit comments

Comments
 (0)