adi1090x / rofi

A huge collection of Rofi based custom Applets, Launchers & Powermenus.
GNU General Public License v3.0
6.51k stars 303 forks source link

syntax error on running menu_powermenu #52

Closed satyajitghana closed 2 years ago

satyajitghana commented 3 years ago
❯ menu_powermenu
/home/shadowleaf/.config/rofi/bin/usedcpu: 8: [[: not found
/home/shadowleaf/.config/rofi/bin/usedcpu: 14: Syntax error: "(" unexpected
/home/shadowleaf/.config/rofi/bin/usedram: 4: Bad substitution
/home/shadowleaf/.config/rofi/bin/usedram: 17: [[: not found
/home/shadowleaf/.config/rofi/bin/usedram: 19: [[: not found
/home/shadowleaf/.config/rofi/bin/usedram: 23: [[: not found

I'm on zsh

hartontw commented 3 years ago
nano menu_powermenu

Replace sh to bash

cpu=$(bash ~/.config/rofi/bin/usedcpu)
memory=$(bash ~/.config/rofi/bin/usedram)
ghost commented 3 years ago

It's not even neccessary to call bash at all, the permissions allow for direct execution. Pull request https://github.com/adi1090x/rofi/pull/59 should fix this issue.