You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

"1" zero-length file created in home directory when term window opened

What is the zero-length file named "1" which is created in the home directory whenever a term window is opened?


It happens whether the window is opened from Terminal or iTerm. The date on the file is updated each time a new window is opened.


Any ideas what the purpose might be? Removing it is harmless; it is just recreated the next time a term window opens.

iMac 27″ 5K, macOS 10.15

Posted on Jul 31, 2020 6:22 AM

Reply

Similar questions

2 replies

Jul 31, 2020 11:54 AM in response to Barney-15E

Absolutely right! But it took a little searching to find it. At the end of my .zshrc is:


if command -v pyenv >/dev/null 2&>1; then

eval "$(pyenv init -)"

fi


And that was what was doing it. I actually checked what the command did, and it was doing nothing worth mentioning. And then I looked closer at the line (which based on something in the pyenv init was installed by homebrew).


Note the redirection: It has 2&>1 rather than 2>&1.


Thanks for pointing me to the answer.


"1" zero-length file created in home directory when term window opened

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