노트북 터치패드(touchpad) On/Off toggle 스크립트

근래 작업용 노트북이 필요하여 다시 셋팅하다 보니, 타이핑 칠때 마다 터치패드가 나를 불편하게 만드네요.

간단한 toggle 명령 하나 만들어봄.

 

# cat /usr/bin/tponoff

#!/bin/bash

TP_ID=`xinput | grep TouchPad | awk ‘{print $6}’ | sed -e ‘s/id=//g’`
echo “TouchPad ID : $TP_ID”

#xinput list-props $TP_ID | grep “Device Enabled”

TP_ST=`xinput list-props $TP_ID | grep “Device Enabled” | cut -d : -f 2 | sed -e ‘s/<tab표식>//g’`

if [ “$TP_ST” = “0” ] ; then
echo “TouchPad status change from Off to On”
xinput enable $TP_ID
else
echo “TouchPad status change from On to Off”
xinput disable $TP_ID
fi

TP_ST1=`xinput list-props $TP_ID | grep “Device Enabled” | cut -d : -f 2 | sed -e ‘s/<tab표식>//g’`
echo “TouchPad Status : $TP_ST1”

 

서진우

슈퍼컴퓨팅 전문 기업 클루닉스/ 상무(기술이사)/ 정보시스템감리사/ 시스존 블로그 운영자

You may also like...

11 Responses

  1. gate io 말해보세요:

    Cool. I spent a long time looking for relevant content and found that your article gave me new ideas, which is very helpful for my research. I think my thesis can be completed more smoothly. Thank you.

  2. Mail Tm 말해보세요:

    Hi there to all, for the reason that I am genuinely keen of reading this website’s post to be updated on a regular basis. It carries pleasant stuff.

  3. Restore CBD Gummies 말해보세요:

    I do believe all the ideas youve presented for your post They are really convincing and will certainly work Nonetheless the posts are too short for novices May just you please lengthen them a little from subsequent time Thanks for the post

  4. temptemail 말해보세요:

    I had a great time with that, too. Despite the high quality of the visuals and the prose, you find yourself eagerly anticipating what happens next. If you decide to defend this walk, it will basically be the same every time.

  5. Puravive Benefits 말해보세요:

    Hi Neat post Theres an issue together with your web site in internet explorer may test this IE still is the marketplace chief and a good component of people will pass over your fantastic writing due to this problem

  6. mail log 말해보세요:

    Hi, I truly appreciate what you posted. Could we discuss your topic in more detail on AOL? I think you might be the expert in this sector I need to help me with my issue. It will be a pleasure to talk to you.

  7. yotmail 말해보세요:

    It seems like you have a great deal of knowledge about this—almost like you wrote the book on it. Aside from that, I think you might add a few graphics to assist illustrate the concept a bit better. Still, this is a fantastic post that is well worth reading, and I will surely be back.

  8. yotmail 말해보세요:

    I thought you did a great job here. The wording is excellent and the illustration is tasteful, but there’s a feeling that you might be giving more, which would probably happen again if you go on this walk.

  9. howwtalliss 말해보세요:

    Fantastic site Lots of helpful information here I am sending it to some friends ans additionally sharing in delicious And of course thanks for your effort

  1. 2022년 6월 18일

    1appreciable

  2. 2023년 1월 26일

    1crispin

페이스북/트위트/구글 계정으로 댓글 가능합니다.