Skip to main content

TUI that allows creating and replaying uinput devices from libinput recordings

Project description

unplug

unplug is a Python TUI that allows creating and replaying uinput devices from libinput recordings.

unplug requires write access to /dev/uinput, so it needs to be run as root or with the appropriate permissions set on the /dev/uinput node.

Installation

$ pip install unplug
# allow access to uinput for the time being (or run as root)
$ sudo chmod o+rw /dev/uinput
$ unplug

This will search for any .yml file in the current directory and if it looks like a valid libinput record file, it will load it into the available list of devices.

Where the device name/vid/pid is the same, multiple recordings are collated into the same device within unplug, so the

See the libinput documentation for details on libinput record.

Running from git

$ git clone https://gitlab.freedesktop.org/whot/unplug.git
$ cd unplug
$ uv run unplug

Updating recordings

To create recordings, you can use the libinput record command:

$ sudo libinput record --output recording.yml
# select device, record a few events, ctrl+c

Adding the (optional) unplug.name and unplug.description keys to the recording file will allow you to name the recording in the unplug TUI:

# libinput record
version: 1
ndevices: 1
libinput:
  version: "1.28.903"
  git: "unknown"
# Add the unplug.name key as description of this recording
unplug:
  name: "Key A press/release"
  description: any short markdown

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

unplug-0.1.0.tar.gz (31.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

unplug-0.1.0-py3-none-any.whl (19.6 kB view details)

Uploaded Python 3

File details

Details for the file unplug-0.1.0.tar.gz.

File metadata

  • Download URL: unplug-0.1.0.tar.gz
  • Upload date:
  • Size: 31.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.4.25

File hashes

Hashes for unplug-0.1.0.tar.gz
Algorithm Hash digest
SHA256 5221f967ecae0d76ab94aaed942366b8b86cac9ab06b50b05575ef4016d24754
MD5 786c14db194d2c48e9dc770634c23ea7
BLAKE2b-256 e570f69315608fec08ee77461f15bf8dd76b901985bfa95ac63f33f821535df8

See more details on using hashes here.

File details

Details for the file unplug-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: unplug-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 19.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.4.25

File hashes

Hashes for unplug-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 64f5e9096426f246b1e8d1556b874f71e573f94ef0b2520082a03007a0edcc8d
MD5 2b8245821e67b5e0c01aed0ec4b3ac4c
BLAKE2b-256 d3680c76acd70db194cd38332382bb10d7da082a39c3d245ba901dcd64088e52

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page