Skip to content

Commit

Permalink
silence stderr from ls command in cron
Browse files Browse the repository at this point in the history
This occurs on devices without an mt76 phy
  • Loading branch information
maurerle authored Aug 30, 2024
1 parent 9ed9621 commit 0db5b86
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/sh
if ls /sys/kernel/debug/ieee80211/phy*/mt76/rf_regval > /dev/null && ! cat /sys/kernel/debug/ieee80211/phy*/mt76/rf_regval > /dev/null; then
if ls /sys/kernel/debug/ieee80211/phy*/mt76/rf_regval 2>&1 > /dev/null && ! cat /sys/kernel/debug/ieee80211/phy*/mt76/rf_regval > /dev/null; then

Check warning on line 2 in ffac-mt7915-hotfix/files/lib/gluon/mt7915/reboot-on-error.sh

View workflow job for this annotation

GitHub Actions / shellcheck

[shellcheck] ffac-mt7915-hotfix/files/lib/gluon/mt7915/reboot-on-error.sh#L2 <ShellCheck.SC2069>

To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).
Raw output
./ffac-mt7915-hotfix/files/lib/gluon/mt7915/reboot-on-error.sh:2:55: warning: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify). (ShellCheck.SC2069)
logger -s -t "ffac-mt7915-hotfix" -p err "wifi firmware crashed, scheduled reboot in 5 seconds"
sleep 5
# Autoupdate?
Expand Down

0 comments on commit 0db5b86

Please sign in to comment.