Skip to content

Conversation

@wight554
Copy link

  • to prevent file "no such file or directory" spam if it doesn't

* to prevent file no such file or directory spam if it doesn't

# Battery optimization
if grep -q "$app" /data/system/deviceidle.xml; then
if [[ -f /data/system/deviceidle.xml ]] && grep -q "$app" /data/system/deviceidle.xml; then
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could just be grep -q [...] 2> /dev/null, so there's no need for an extra check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants