Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Prompt themes masking output from some applications [macOS]



Issue:

Using a simple Apple shortcut app (called apc) as an example that returned some textual, 
number or date output I tried the following. 

> shortcuts run apc | cat

I could not get any output 

This used to work. However, using the following methods I could see still the result

>  shortcuts run apc | xargs
>  cat <<< $(shortcuts run apc)

I found that the issue was caused by the following, added to the system /etc/zshrc 
by a third-party package management and configuration utility called Nix and Darwin-Nix.
It called an autogenerated generated file under /etc/static/zshrc which had the following line.

> autoload -U promptinit && promptinit && prompt walters

The output was there all along it was the prompt theme writing over it.
This was so fast it gave the appearance that nothing was printed.

A Temporary fix is to comment out 

# autoload -U promptinit && promptinit && prompt walters

Or turn the prompt theme off at some point in the shell configuration.

> prompt off

I believe that there may be an issue at  /Functions/Prompts/ 

https://sourceforge.net/p/zsh/code/ci/master/tree/Functions/Prompts/

Not sure if it is promptinit or something in individual themes.










Messages sorted by: Reverse Date, Date, Thread, Author