I am missing the .zshrc file in home directory

I am not able to find the .zshrc file in the home directory when executed %ls -la ~/ command



[Re-Titled by Moderator]

Posted on Jan 27, 2025 11:39 AM

Reply
Question marked as Top-ranking reply

Posted on Jan 27, 2025 11:59 AM

You do not need ~/ just ~ to list your home directory.


Copy and paste the following into your Terminal and then press return. It will create the .zshrc file with a basic PATH and shell prompt for you.


<<"EOF" > ~/.zshrc
export PATH=".:/usr/local/bin:${PATH}"
PS1="%m: %~ %% "
EOF


Once that is done, issue the following command to make the contents of that .zshrc file current. Your shell prompt will change.

source ~/.zshrc


2 replies
Question marked as Top-ranking reply

Jan 27, 2025 11:59 AM in response to shanthi2025

You do not need ~/ just ~ to list your home directory.


Copy and paste the following into your Terminal and then press return. It will create the .zshrc file with a basic PATH and shell prompt for you.


<<"EOF" > ~/.zshrc
export PATH=".:/usr/local/bin:${PATH}"
PS1="%m: %~ %% "
EOF


Once that is done, issue the following command to make the contents of that .zshrc file current. Your shell prompt will change.

source ~/.zshrc


This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

I am missing the .zshrc file in home directory

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.