Skip to content

Commit

Permalink
Add ionice for better pogo performance
Browse files Browse the repository at this point in the history
  • Loading branch information
Astu04 authored Dec 22, 2023
1 parent 4444cc1 commit cfbcd24
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions custom/ATVServices.sh
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,17 @@ if result=$(check_mitmpkg); then
sleep 60
fi

# Check if com.nianticlabs.pokemongo is running
BUSYBOX_PS_OUTPUT=$(busybox ps | grep -E "com\.nianticlabs\.pokemongo")

# Check if the process is running and adjust I/O priority if found
if [ -n "$BUSYBOX_PS_OUTPUT" ]; then
echo "com.nianticlabs.pokemongo is running. Adjusting I/O priority..."
ionice -p $(pidof com.nianticlabs.pokemongo) -c 0 -n 0
else
echo "com.nianticlabs.pokemongo is not running."
fi

log -p i -t eMagiskATVService "Started health check!"
response=$(curl -s -w "%{http_code}" --cacert "$cacert_path" -u "$rdm_user":"$rdm_password" "$rdm_backendURL/api/get_data?show_devices=true&formatted=false")
statusCode=$(echo "$response" | tail -c 4)
Expand Down

0 comments on commit cfbcd24

Please sign in to comment.