evdev.cr

evdev.cr

Crystal bindings to libevdev.

API Documentation

Documentation

As these bindings are effectively just a wrapper (i.e. minimal abstraction), behavior is identical to that described in the libevdev docs unless otherwise specified.

Installation

  1. Add the dependency to your shard.yml:

    dependencies:
      evdev:
        github: nickbclifford/evdev.cr
    
  2. Run shards install

Usage

require "evdev"

File.open("/dev/input/event0") do |file|
  device = Evdev::Device.from_file(file)
  puts device.name
end

Contributing

  1. Fork it (https://github.com/nickbclifford/evdev.cr/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

Repository

evdev.cr

Owner
Statistic
  • 4
  • 0
  • 0
  • 1
  • 0
  • about 3 years ago
  • April 11, 2021
License

MIT License

Links
Synced at

Sun, 05 May 2024 12:25:36 GMT

Languages