Refactor structure

Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
2025-01-09 13:50:26 +00:00
parent c8c34c40e5
commit b355f72b2e
30 changed files with 362 additions and 202 deletions

View File

@@ -0,0 +1,14 @@
SEARCH_STRINGS=(
"Mouse"
"Razer DeathAdder Elite"
"Razer DeathAdder V3 HyperSpeed"
)
for search_string in "${SEARCH_STRINGS[@]}"; do
echo "Searching for devices matching: ${search_string}"
for f in $(grep -l "${search_string}" /sys/bus/usb/devices/*/product 2>/dev/null | sed "s/product/power\\/control/"); do
echo "Setting power control to 'on' for: ${f}"
echo on >| "${f}"
done
done