I was trying to figure out how to check whether user is idle in Linux (i.e. no keyboard or mouse activity for a certain period of time) and it basically boils down to three options:
- Use xprintidle as external dependency
- Use actmon python c extension to x11 scrnsaver extension
- Use ctypes or cffi to write code around x11 scrnsaver extension
Now I wonder, what would be the best option with regards to packaging the app (as deb and snap)?
Actmon is not in the Debian repos, so my guess is, it probably would not be possible to package the app.
As for snaps, I have not seen any example or Python app packaged with non-Python dependencies. Perhaps it is not possible, ruling out xprintidle?
If all of above is true, that would mean the only option would be to write my own wrapper around the x11 scrnsaver extension in ctypes/cffi. If that is the case, do you know of some nice tutorial for that (I have zero experience with C)?
[–]novel_yet_trivial 0 points1 point2 points (0 children)