mirror of
https://gitlab.com/mlunax/dotfiles.git
synced 2025-04-18 16:26:50 +00:00
post-laptop-install and touchpad.sh
This commit is contained in:
parent
a05961aba4
commit
b99ddaa27e
2 changed files with 21 additions and 0 deletions
12
.local/scripts/touchpad.sh
Executable file
12
.local/scripts/touchpad.sh
Executable file
|
@ -0,0 +1,12 @@
|
|||
#!/bin/bash
|
||||
fileName=/tmp/touchpad
|
||||
id=$(xinput | grep TouchPad |grep -Poh '(?<=id\=)[0-9]+')
|
||||
if [[ ! -f $fileName ]]; then
|
||||
echo "$id" > $fileName
|
||||
xinput --disable $id
|
||||
notify-send "Touchpad disabled" -t 1000 -u low
|
||||
else
|
||||
xinput --enable $(cat $fileName)
|
||||
rm $fileName
|
||||
notify-send "Touchpad enabled" -t 1000 -u low
|
||||
fi
|
9
post-laptop-install.sh
Normal file
9
post-laptop-install.sh
Normal file
|
@ -0,0 +1,9 @@
|
|||
#!/usr/bin/env bash
|
||||
scripts_path_prefix="./.local/.scripts"
|
||||
laptop_scripts=("touchpad.sh")
|
||||
for i in ${laptop_scripts[@]}; do
|
||||
path="$scripts_path_prefix/$i"
|
||||
if [ -f $path ]; then
|
||||
cp -iv $path $HOME/$path
|
||||
fi
|
||||
done
|
Loading…
Add table
Reference in a new issue