#!/bin/sh set -euC name() { xinput list --name-only | grep -i "$1" | grep -vi 'virtual' } xinput float "$(name keyboard)" xinput float "$(name touchpad)"