Neofetch: Neofetch displaying wrong shell version

Created on 18 Sep 2017  Â·  9Comments  Â·  Source: dylanaraps/neofetch

Description

When using neofetch, it's displaying the wrong shell version, while screenfetch displays the correct shell version. It's displaying zsh 5.3 instead of 5.4.1

Neofetch version

Kevin ➜ ~ neofetch --version
Neofetch 3.2.0

Screenshot

screen shot 2017-09-18 at 11 02 10 am

Config file

Default

Verbose log

https://pastebin.com/sPZ1jYsU

Not our bug

All 9 comments

What's the output of zsh --version?

Kevin ➜ ~ zsh --version
zsh 5.4.1 (x86_64-apple-darwin17.0.0)
Kevin ➜ ~

What's the output of $SHELL --version?

Screenfetch uses the parent process instead of $SHELL on Linux. Which makes no sense to me.

Kevin ➜ ~ $SHELL --version
zsh 5.3 (x86_64-apple-darwin17.0)
Kevin ➜ ~

Huh that's odd..

Your shell is incorrectly configured, as far as I'm concerned neofetch is working correctly.

Screenfetch works because it isn't using your current shell, it's using whatever shell started Screenfetch which in my opinion doesn't accurately display your shell.

I was experiencing this issue as well. I'm running macOS Mojave 10.14.6 and using oh-my-zsh. My current shell is definitely zsh 5.7.1, and screenfetch is accurately displaying my shell as such.

I think the issue is oh-my-zsh updating the ZSH path which causes the value of$SHELL to become inaccurate. I fixed the issue by adding this line to my zshrc:

export SHELL=zsh

now neofetch is showing my shell accruately.

Neofetch uses $SHELL to grab your current shell. If this displays something unexpected, your shell is incorrectly configured or you're setting your shell outside of $SHELL. This isn't a Neofetch issue.

In some cases the $SHELL environment variable can not match the current shell which causes Neofetch to display inaccurate information. If you don't see that as a Neofetch issue, that's fine and I tend to agree, it's more of an oh-my-zsh issue IMHO... but it's something that some users (e.g. oh-my-zsh + Mac) may encounter and given that this is the first link that comes up for the issue on Google, I thought that - at the very least - it would be helpful to leave a comment with the remedy.

I have the same problem. when a newer version of ZSH is installed (in my case via brew), neofetch will only display the version which is installed by default on macOS not the one which is currently used.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dylanaraps picture dylanaraps  Â·  3Comments

dylanaraps picture dylanaraps  Â·  10Comments

zoenglinghou picture zoenglinghou  Â·  6Comments

pelomedusa picture pelomedusa  Â·  4Comments

shawniac picture shawniac  Â·  4Comments