brunophilipe / Cakebrew

Manage your Homebrew formulas with style using Cakebrew.
http://www.cakebrew.com
GNU General Public License v3.0
4.8k stars 253 forks source link

No formulae available #242

Open veics opened 2 years ago

veics commented 2 years ago

I don't have any formulae displayed as installed, all categories are showing "2", and the rows are populated with `tput: No value for $TERM and no -T specified".

I have 11.6 + bash as default shell.

If I start "Cakebrew" from command line, everything works fine.

drpoutine commented 2 years ago

@veics your ps1 customizations dont work on non interactive shells. you have to update your bash_profile/bashrc with if checks

superatomic commented 2 years ago

@veics As a quick fix, wherever you use tput § in your startup files, you can instead run [ -n "$TERM" ] && tput §* or [ -t 0 ] && tput §, where § is whatever arguments you provide to tput.

For example, replace a line like export COLOR_GREEN="$(tput setaf 2)" with export COLOR_GREEN="$([ -t 0 ] && tput setaf 2)"

It might cause false positives in cases where you want tput to run, but it makes Cakebrew work.

*Untested, but probably better