You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
378 B

#!/bin/sh
## Toggle the state of the fnmode.
## Useful for using keyboards with different fn functionality.
curr=$(cat /sys/module/hid_apple/parameters/fnmode)
if [ "$curr" = "1" ]
then
echo "0" | sudo tee -a /sys/module/hid_apple/parameters/fnmode > /dev/null
elif [ "$curr" = "0" ]
then
echo "1" | sudo tee -a /sys/module/hid_apple/parameters/fnmode > /dev/null
fi