Hacker News new | past | comments | ask | show | jobs | submit login

"please lose your entire scroll buffer before this works, even though there's a way to use brew right now without doing that" isn't really going to win anyone favours. In cases like these: just ask the user what they want to do.

> For brew to be available as command, brew needs to update your path and [bash/zsh/etc] profile. Please select how you wish to continue:

> 1. Please do this for me

> 2. Explain what you're about to do first, then ask me again.

> 3. No thanks. I'll do this myself.

And then you also make sure there's a runtime flag or even env var that can be used to override this, for admins who need to install brew as part of mass deploys.




> please lose your entire scroll buffer before this works

FWIW, some variation on:

  $ exec bash
ought to work, since what you care about is restarting the shell (.bashrc,PATH,etc), rather than the terminal per se.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: