Skip to content
Advertisement

Bash – Retrieve ID From A String (xinput) Received From A Pipe

When I run the following command it returns me the information of my current mouse:-

JavaScript

What command should I execute (maybe along with some regex) that I can get an output 13 (in current case).

Something like this:-

JavaScript

Advertisement

Answer

JavaScript

Or even shorter :

JavaScript
User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement