ejectable

Description

Eject and close tray on your devices.

Features

  • Eject tray
  • Close tray

Usage

Setup

require 'ejectable'

Use via method

include Ejectable

eject_tray '/dev/cdrom' #=> true

Use device class

device = Ejectable::Device.new '/dev/cdrom'
device.eject_tray

Auto closing after operation

device.eject_tray! do
  sleep 5
end

Requirements

Note

Wrapping eject command now. And I guess runnable only Linux. :(

Install

git-repos

git clone https://github.com/kachick/ejectable.git
gem build ejectable.gemspec
gem install ./ejectable

rubygems.org

gem install ejectable

Build Status

Build Status

Link

License

The MIT X11 License
Copyright (c) 2013 Kenichi Kamiya
See MIT-LICENSE for further details.