Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
/_yardoc/
/coverage/
/doc/
/lib/
/logs/
/pkg/
/spec/reports/
Expand Down
2 changes: 0 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ gemspec

group :development do
gem "rake"
gem "rake-compiler"
gem "test-unit"
gem "test-unit-ruby-core"
gem 'ruby-maven', :platforms => :jruby
end
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

This gem provides the feature for waiting until IO is readable or writable without blocking.

**Note:** This gem is empty and deprecated. All functionality was moved into core Ruby as of version 3.2.

## Installation

Add this line to your application's Gemfile:
Expand Down
28 changes: 1 addition & 27 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,37 +1,11 @@
require "bundler/gem_tasks"
require "rake/testtask"

name = "io/wait"

case
when RUBY_ENGINE == "jruby"
require 'rake/javaextensiontask'
Rake::JavaExtensionTask.new("wait") do |ext|
require 'maven/ruby/maven'
ext.source_version = '1.8'
ext.target_version = '1.8'
ext.ext_dir = 'ext/java'
ext.lib_dir = 'lib/io'
end
task "build" => "lib/io/wait.jar"
task "lib/io/wait.jar" => "compile"
libs = ["ext/java/lib", "lib"]
else
require 'rake/extensiontask'
extask = Rake::ExtensionTask.new(name) do |x|
x.lib_dir.sub!(%r[(?=/|\z)], "/#{RUBY_VERSION}/#{x.platform}")
end
libs = ["lib/#{RUBY_VERSION}/#{extask.platform}"]
end

Rake::TestTask.new(:test) do |t|
t.libs = libs
t.libs << "test/lib"
t.libs = ["lib", "test/lib"]
t.ruby_opts << "-rhelper"
t.options = "--ignore-name=/ungetc_in_text/"
t.test_files = FileList["test/**/test_*.rb"]
end

task :test => :compile

task :default => :test
18 changes: 0 additions & 18 deletions ext/io/wait/depend

This file was deleted.

4 changes: 0 additions & 4 deletions ext/io/wait/extconf.rb

This file was deleted.

23 changes: 0 additions & 23 deletions ext/io/wait/wait.c

This file was deleted.

2 changes: 0 additions & 2 deletions ext/java/lib/io/wait.rb

This file was deleted.

43 changes: 0 additions & 43 deletions ext/java/org/jruby/ext/io/wait/IOWaitLibrary.java

This file was deleted.

16 changes: 3 additions & 13 deletions io-wait.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,18 @@ Gem::Specification.new do |spec|
spec.authors = ["Nobu Nakada", "Charles Oliver Nutter"]
spec.email = ["nobu@ruby-lang.org", "headius@headius.com"]

spec.summary = %q{Waits until IO is readable or writable without blocking.}
spec.description = %q{Waits until IO is readable or writable without blocking.}
spec.summary = %q{Deprecated: All functionality ships with Ruby 3.2 and higher.}
spec.description = %q{Deprecated: All functionality ships with Ruby 3.2 and higher.}
spec.homepage = "https://github.com/ruby/io-wait"
spec.licenses = ["Ruby", "BSD-2-Clause"]
spec.required_ruby_version = Gem::Requirement.new(">= 3.2")

spec.metadata["homepage_uri"] = spec.homepage
spec.metadata["source_code_uri"] = spec.homepage

jruby = true if Gem::Platform.new('java') =~ spec.platform or RUBY_ENGINE == 'jruby'
dir, gemspec = File.split(__FILE__)
excludes = [
*%w[:^/.git* :^/Gemfile* :^/Rakefile* :^/bin/ :^/test/ :^/rakelib/ :^*.java],
*(jruby ? %w[:^/ext/io] : %w[:^/ext/java]),
*%w[:^/.git* :^/Gemfile* :^/Rakefile* :^/bin/ :^/test/ :^/rakelib/],
":(exclude,literal,top)#{gemspec}"
]
files = IO.popen(%w[git ls-files -z --] + excludes, chdir: dir, &:read).split("\x0")
Expand All @@ -28,12 +26,4 @@ Gem::Specification.new do |spec|
spec.bindir = "exe"
spec.executables = []
spec.require_paths = ["lib"]

if jruby
spec.platform = 'java'
spec.files << "lib/io/wait.jar"
spec.require_paths += ["ext/java/lib"]
else
spec.extensions = %w[ext/io/wait/extconf.rb]
end
end
1 change: 1 addition & 0 deletions lib/io/wait.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
warn "The io-wait gem is deprecated; all functionality ships with Ruby 3.2 and higher."
Loading