Skip to main content

A tool to record and play back keyboard and mouse inputs.

Project description

Header

Description

This project enables the recording of keyboard and mouse inputs, which can be played back with looping functionality using the pynput library. It is designed to facilitate the automation of repetitive computer tasks efficiently, whatever they may be.

Installation

Install via PyPi

You can install this package directly from PyPi:

pip install record-and-play-pynput

Install from GitHub

Alternatively, you can clone the repository and install the dependencies manually:

  1. Clone or download this repository:
git clone https://github.com/george-jensen/record-and-play-pynput.git
  1. Navigate to the repository directory:
cd record-and-play-pynput
  1. Install the required dependencies using Poetry:
poetry install

Usage

Recording

  1. Run the record command, specifying the required name_of_recording argument. Example:
record-and-play record -n <name_of_recording>

All keyboard and mouse activity will be recorded.

  1. To end the recording:
  • Press the Escape key to stop the keyboard recording.
  • Hold the right mouse button for more than 2 seconds without moving the mouse, then release to stop the mouse recording.

Playback

  1. Run the play command, specifying the name_of_recording and the number_of_requests arguments. Example:
record-and-play play -n <name_of_recording> -p <number_of_repeats>
  1. To stop the playback early, trigger a KeyboardInterrupt by pressing Ctrl+C in the terminal window.

Notes

Scrolling functionality is supported, however it is not completely precise. So it is recommended to drag scrollbars when available. If you find you need to scroll to the top or bottom of pages then try and over-compensate when recording before continuing.

Compatablitity

At the moment this is Mac compatible - I haven't been able to find a Mac compatible tool that does a similar job and that is one of the reasons for this repository's creation.

It has recently been brought to my attention that there are issues with Windows compatability. I will try and address these soon.

Authors

George Jensen

Support!

If you found this tool useful please give this repo a star!

Please also feel free to create an issue to give feedback on any bugs, or ask for improvements! I'm always keen to keep things up to date and useful so any and all feedback is welcome!

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

record_and_play_pynput-0.1.2.tar.gz (11.6 kB view details)

Uploaded Source

Built Distribution

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

record_and_play_pynput-0.1.2-py3-none-any.whl (12.6 kB view details)

Uploaded Python 3

File details

Details for the file record_and_play_pynput-0.1.2.tar.gz.

File metadata

  • Download URL: record_and_play_pynput-0.1.2.tar.gz
  • Upload date:
  • Size: 11.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.3 Darwin/23.5.0

File hashes

Hashes for record_and_play_pynput-0.1.2.tar.gz
Algorithm Hash digest
SHA256 8740746dfba156ee10b2f48e2f0b7738e5e74730fbbdce293f3c8b7d49658a65
MD5 e5c3d127909d5cdb5e78b213f1ea6f09
BLAKE2b-256 8a0ecc1bdc922d241a19496f64f97ac9c4a9c93314bdea227c0a5b7a8325a227

See more details on using hashes here.

File details

Details for the file record_and_play_pynput-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for record_and_play_pynput-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 0847a18c7c2e317f2a0088566ecf14f137f2b9346a00f934f11369c594b349e1
MD5 22cb87ce68393211828ae01c3a2d8ff1
BLAKE2b-256 75a900bf1d44d0532da54a9ab826f02f818945edb5d7e2c212de46124c2a1d33

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