[前][次][番号順一覧][スレッド一覧]

ruby-changes:58665

From: Hiroshi <ko1@a...>
Date: Sat, 9 Nov 2019 07:43:10 +0900 (JST)
Subject: [ruby-changes:58665] 2a0ed5691e (master): Promote timeout to default gems

https://git.ruby-lang.org/ruby.git/commit/?id=2a0ed5691e

From 2a0ed5691efbc602a4403ec09e6f91e89baa5507 Mon Sep 17 00:00:00 2001
From: Hiroshi SHIBATA <hsbt@r...>
Date: Fri, 8 Nov 2019 19:21:47 +0900
Subject: Promote timeout to default gems


diff --git a/doc/maintainers.rdoc b/doc/maintainers.rdoc
index 062c492..57a7aa4 100644
--- a/doc/maintainers.rdoc
+++ b/doc/maintainers.rdoc
@@ -93,8 +93,6 @@ Zachary Scott (zzak) https://github.com/ruby/ruby/blob/trunk/doc/maintainers.rdoc#L93
   _unmaintained_
 [lib/time.rb]
   Tanaka Akira (akr)
-[lib/timeout.rb]
-  Yukihiro Matsumoto (matz)
 [lib/tsort.rb]
   Tanaka Akira (akr)
 [lib/un.rb]
@@ -257,6 +255,9 @@ Zachary Scott (zzak) https://github.com/ruby/ruby/blob/trunk/doc/maintainers.rdoc#L255
   Yukihiro Matsumoto (matz)
   https://github.com/ruby/singleton
   https://rubygems.org/gems/singleton
+[lib/timeout.rb]
+  Yukihiro Matsumoto (matz)
+  https://github.com/ruby/timeout
 [lib/thwait.rb]
   Keiju ISHITSUKA (keiju)
   https://github.com/ruby/thwait
diff --git a/doc/standard_library.rdoc b/doc/standard_library.rdoc
index dc777b4..0ffa6e5 100644
--- a/doc/standard_library.rdoc
+++ b/doc/standard_library.rdoc
@@ -34,7 +34,6 @@ Set:: Provides a class to deal with collections of unordered, unique values https://github.com/ruby/ruby/blob/trunk/doc/standard_library.rdoc#L34
 Shellwords:: Manipulates strings with word parsing rules of UNIX Bourne shell
 Tempfile:: A utility class for managing temporary files
 Time:: Extends the Time class with methods for parsing and conversion
-Timeout:: Auto-terminate potentially long-running operations in Ruby
 tmpdir.rb:: Extends the Dir class to manage the OS temporary file path
 TSort:: Topological sorting using Tarjan's algorithm
 un.rb:: Utilities to replace common UNIX commands
@@ -86,6 +85,7 @@ RDoc:: Produces HTML and command-line documentation for Ruby https://github.com/ruby/ruby/blob/trunk/doc/standard_library.rdoc#L85
 REXML:: An XML toolkit for Ruby
 RSS:: Family of libraries that support various formats of XML "feeds"
 Singleton:: Implementation of the Singleton pattern for Ruby
+Timeout:: Auto-terminate potentially long-running operations in Ruby
 Tracer:: Outputs a source level execution trace of a Ruby program
 WEBrick:: An HTTP server toolkit for Ruby
 
diff --git a/lib/timeout/timeout.gemspec b/lib/timeout/timeout.gemspec
new file mode 100644
index 0000000..88babe9
--- /dev/null
+++ b/lib/timeout/timeout.gemspec
@@ -0,0 +1,27 @@ https://github.com/ruby/ruby/blob/trunk/lib/timeout/timeout.gemspec#L1
+begin
+  require_relative "lib/timeout/version"
+rescue LoadError # Fallback to load version file in ruby core repository
+  require_relative "version"
+end
+
+Gem::Specification.new do |spec|
+  spec.name          = "timeout"
+  spec.version       = Timeout::VERSION
+  spec.authors       = ["Yukihiro Matsumoto"]
+  spec.email         = ["matz@r..."]
+
+  spec.summary       = %q{Auto-terminate potentially long-running operations in Ruby.}
+  spec.description   = %q{Auto-terminate potentially long-running operations in Ruby.}
+  spec.homepage      = "https://github.com/ruby/timeout"
+  spec.license       = "BSD-2-Clause"
+
+  spec.metadata["homepage_uri"] = spec.homepage
+  spec.metadata["source_code_uri"] = spec.homepage
+
+  spec.files         = Dir.chdir(File.expand_path('..', __FILE__)) do
+    `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
+  end
+  spec.bindir        = "exe"
+  spec.executables   = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
+  spec.require_paths = ["lib"]
+end
diff --git a/lib/timeout/version.rb b/lib/timeout/version.rb
new file mode 100644
index 0000000..39fc6ee
--- /dev/null
+++ b/lib/timeout/version.rb
@@ -0,0 +1,3 @@ https://github.com/ruby/ruby/blob/trunk/lib/timeout/version.rb#L1
+module Timeout
+  VERSION = "0.1.0"
+end
diff --git a/tool/sync_default_gems.rb b/tool/sync_default_gems.rb
index 49b48c2..af9a9ae 100644
--- a/tool/sync_default_gems.rb
+++ b/tool/sync_default_gems.rb
@@ -45,6 +45,7 @@ https://github.com/ruby/ruby/blob/trunk/tool/sync_default_gems.rb#L45
 # * https://github.com/ruby/readline
 # * https://github.com/ruby/readline-ext
 # * https://github.com/ruby/observer
+# * https://github.com/ruby/timeout
 #
 
 require 'fileutils'
@@ -97,6 +98,7 @@ $repositories = { https://github.com/ruby/ruby/blob/trunk/tool/sync_default_gems.rb#L98
   readline: "ruby/readline",
   readlineext: "ruby/readline-ext",
   observer: "ruby/observer",
+  timeout: "ruby/timeout",
 }
 
 def sync_default_gems(gem)
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]