aboutsummaryrefslogtreecommitdiff
path: root/i3/blocks/usb
blob: e294e7daf22ad6b89bb042a203f38ebdb3cd91bc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/bash

DEVICE_NAME="${BLOCK_INSTANCE:-Keyboard}"

DEVICE_INFO=$(lsusb | grep -i "${DEVICE_NAME}")

if [[ "${DEVICE_INFO}" != "" ]]; then
  echo "on"
  echo "on"
  echo ""
else
  echo "na"
  echo "na"
  echo ""
fi