KittyKatt / screenFetch

Fetches system/theme information in terminal for Linux desktop screenshots.
GNU General Public License v3.0
3.86k stars 455 forks source link

awk: can't open file /proc/cpuinfo #750

Open flyweb291 opened 2 years ago

flyweb291 commented 2 years ago

I type screenfetch and it prompts for awk: can't open file /proc/cpuinfo and grep: /proc/cpuinfo: No such file or directory

image

I can't find /proc/cpuinfo in the file either

image image
bowwowxx commented 2 years ago

I have the same problem, my notebook is mac m1 pro 16, I found the information of /usr/bin/sw_vers as follows 截圖 2022-09-18 上午3 07 34

So I modified /opt/homebrew/Cellar/screenfetch/3.9.1/bin/screenfetch The content is if [[ -x /usr/bin/sw_vers ]] && /usr/bin/sw_vers | grep -i 'macOS' >/dev/null; then

Now it looks normal XD 截圖 2022-09-18 上午2 38 53

meetrp commented 1 year ago

To support legacy MacOS version string, My change was: [Original code] if [[ -x /usr/bin/sw_vers ]] && /usr/bin/sw_vers | grep -i 'Mac OS X' >/dev/null; then [Changed code] if [[ -x /usr/bin/sw_vers ]] && /usr/bin/sw_vers | grep -i -e 'Mac OS X' -e 'macOS' >/dev/null; then