Releases: KarsMulder/evsieve
Version 1.4.0
New Features
New argument: --withhold
When you use a --hook
to trigger an action on a certain key combination, the --withhold
argument can be used to prevent that key combination from reaching the output device.
For example, with the following arguments, you can run a command on pressing Ctrl+A, and the key:a
events will be dropped from the event stream if and only if they were used to trigger that command:
--hook key:leftctrl key:a exec-shell="echo Hello, world!" sequential \
--withhold key:a
The --hook
argument accepts more flags/clauses
The --hook
argument now accepts the following additional flags/clauses: send-key=...
, sequential
, period=...
and breaks-on=...
.
The send-key=...
clause is useful for pressing a key whenever a combination of other keys gets pressed.
The flags/clauses sequential
, period=...
and breaks-on=...
put additional restrictions on when the hook can trigger, and are mostly useful for fine-tuning the behaviour of the new --withhold
argument.
New argument: --delay
The --delay
argument removes events from the event stream and adds them back a fixed amount of time later, effectively delaying events by a fixed amount of time.
Key format extended: event type/code elision
It is now possible to elide the event code or both the event type and code in some places. For example, the filter key::1
will match any key event with value 1, and the filter ::0
will match any event with value 0.
Key format extended: new special values
The special value x
has been added, which is a placeholder for the value of the source event. For example, --map rel ::2x
will double the value of any EV_REL
event, mapping e.g. rel:x:5
to rel:x:10
and mapping rel:y:-4
to rel:y:-8
.
Affine combinations of special values are now allowed as well. For example, if you know that your abs:y
axis takes values in the range [0, 255], then you can use --map abs:y abs:y:255-x
to invert the y axis.
Bugfix / Behaviour Changed
- Whenever a single event is mapped to multiple events, the output devices will now insert an
EV_SYN
synchronisation report between all generated events. Previously the output devices only synchronised when the input devices did. - Trying to use a key with too many colons such as
key:a:1:2
will now give an error. Previously, the:2
part was silently ignored.
Version 1.3.1
Changelog
Bugfix:
- Fixed a bug that could unnecessarily cause virtual output devices to get recreated if an input that is capable of EV_ABS-type events gets reopened using the
persist=reopen
clause.
Version 1.3.0
Changelog
New feature: partial persistence support
Input devices now accept a persist=reopen
clause. If this clause is specified and the input device becomes unavailable (e.g. because some USB cable got disconnected), evsieve will wait until the device becomes available again and then try to reopen it.
The main reason that this persist=reopen
clause is not enabled by default is for backwards compatibility.
New feature: optional systemd integration
When evsieve is ran as a systemd service of Type=notify
, evsieve will notify systemd when it has created its virtual output devices and is ready to start listening for events. This can be used in combination with the systemd-run
tool to conveniently start evsieve in the background from shell scripts. An example shell script is in the README.
Maps can operate on an event type
Mapping all events of a certain type is now possible, e.g. --map key key:space
will map all keyboard keys to the spacebar. Mapping events to a certain type like --map key rel
is still not possible because it has the potential to create invalid (type, code) pairs.
New argument: --merge
The --merge
argument flattens stacked KEY_UP and KEY_DOWN events and is possibly handy if you want to map mulple keys to a single key. For example: if --map key key:space --merge
is used to map an entire keyboard to a spacebar and multiple keys are pressed simultaneously, the --merge
argument will ensure that only a single KEY_DOWN event for the spacebar is generated and the corresponding KEY_UP event is generated only after all keys are released.
Maps can map to relative values
To facilitate mapping abs
to rel
events, a special value d
(short for "delta" or "difference") has been added, which represents the difference between an input event's value and its previous value. It can also scale the difference by an optional factor, for example:
# If an abs:x:10 event gets followed up by a abs:x:50 event, then the latter one gets mapped to rel:x:40.
--map abs:x rel:x:d
# If an abs:y:10 event gets followed up by a abs:y:50 event, then the latter one gets mapped to rel:y:8.
--map abs:y rel:y:0.2d
Version 1.2.0
Changelog
Improvements:
- Evsieve will now print more helpful error messages in many situations.
Bugfix:
- Constructing a value range where the lower bound is greater than the upper bound will now throw an error, e.g. trying to map
key:a:1~0
will throw an error because1
is greater than0
.
Version 1.1.0
Changelog
New feature:
- The
--output
argument now accepts aname=
clause.
Behaviour changed / bugfix:
--toggle
arguments operating in consistent mode now lock active targets for pressed keys based on (keycode, domain) pairs, rather than on keycode alone;--toggle
arguments operating in consistent mode will no longer receive interference from events that do not match its source event.
Toggle arguments operating in consistent mode have received some technically breaking changes. These changes only show up in rare cases; very few scripts will be affected by it. For the scripts that are affected, the new behaviour is in most likelihood the correct/intended behaviour.
Version 1.0.0
This is the first official release of evsieve. The core functionality has been implemented and evsieve has reached a point where it may be useful to others.