Skip to content

Instantly share code, notes, and snippets.

@pstuifzand
Created January 8, 2017 21:06
Show Gist options
  • Save pstuifzand/fef7e2814f36a446f8b55354eedd7348 to your computer and use it in GitHub Desktop.
Save pstuifzand/fef7e2814f36a446f8b55354eedd7348 to your computer and use it in GitHub Desktop.
Log mouse position to csv.
#!/bin/bash
while true; do
xdotool getmouselocation 2>&1 | sed -rn '${s/x:([0-9]+) y:([0-9]+) .*/\1,\2/p}' >> mouselocation.csv
sleep 1
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment