From 43fbdfe806e3052d398a9958662064d2fea2f82b Mon Sep 17 00:00:00 2001 From: hsbt Date: Fri, 20 Jul 2018 01:25:59 +0000 Subject: Promote Tracer to default gems. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- doc/maintainers.rdoc | 4 ++-- doc/standard_library.rdoc | 2 +- lib/tracer.gemspec | 25 +++++++++++++++++++++++++ lib/tracer.rb | 3 +++ tool/sync_default_gems.rb | 9 ++++++++- 5 files changed, 39 insertions(+), 4 deletions(-) create mode 100644 lib/tracer.gemspec diff --git a/doc/maintainers.rdoc b/doc/maintainers.rdoc index 344ed677fe..3ec9178985 100644 --- a/doc/maintainers.rdoc +++ b/doc/maintainers.rdoc @@ -133,8 +133,6 @@ Zachary Scott (zzak) Tanaka Akira (akr) [lib/timeout.rb] Yukihiro Matsumoto (matz) -[lib/tracer.rb] - Keiju ISHITSUKA (keiju) [lib/tsort.rb] Tanaka Akira (akr) [lib/un.rb] @@ -223,6 +221,8 @@ Zachary Scott (zzak) https://github.com/ruby/scanf [lib/sync.rb] Keiju ISHITSUKA (keiju) +[lib/tracer.rb] + Keiju ISHITSUKA (keiju) [lib/webrick.rb, lib/webrick/*] Eric Wong (normalperson) https://bugs.ruby-lang.org/ diff --git a/doc/standard_library.rdoc b/doc/standard_library.rdoc index 5c1e2dc4c3..e9fd533f32 100644 --- a/doc/standard_library.rdoc +++ b/doc/standard_library.rdoc @@ -55,7 +55,6 @@ ThreadsWait:: Watches for termination of multiple threads 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 -Tracer:: Outputs a source level execution trace of a Ruby program TSort:: Topological sorting using Tarjan's algorithm un.rb:: Utilities to replace common UNIX commands URI:: A Ruby module providing support for Uniform Resource Identifiers @@ -95,6 +94,7 @@ REXML:: An XML toolkit for Ruby RSS:: Family of libraries that support various formats of XML "feeds" Scanf:: A Ruby implementation of the C function scanf(3) Synchronizer:: A module that provides a two-phase lock with a counter +Tracer:: Outputs a source level execution trace of a Ruby program WEBrick:: An HTTP server toolkit for Ruby == Extensions diff --git a/lib/tracer.gemspec b/lib/tracer.gemspec new file mode 100644 index 0000000000..b84bcd9b56 --- /dev/null +++ b/lib/tracer.gemspec @@ -0,0 +1,25 @@ +require_relative "lib/tracer" + +Gem::Specification.new do |spec| + spec.name = "tracer" + spec.version = Tracer::VERSION + spec.authors = ["Keiju ISHITSUKA"] + spec.email = ["keiju@ruby-lang.org"] + + spec.summary = %q{Outputs a source level execution trace of a Ruby program.} + spec.description = %q{Outputs a source level execution trace of a Ruby program.} + spec.homepage = "https://github.com/ruby/tracer" + spec.license = "BSD-2-Clause" + + # Specify which files should be added to the gem when it is released. + # The `git ls-files -z` loads the files in the RubyGem that have been added into git. + 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"] + + spec.add_development_dependency "bundler" + spec.add_development_dependency "rake" +end diff --git a/lib/tracer.rb b/lib/tracer.rb index faafd803f4..0c482d1876 100644 --- a/lib/tracer.rb +++ b/lib/tracer.rb @@ -60,6 +60,9 @@ # by Keiju ISHITSUKA(keiju@ishitsuka.com) # class Tracer + + VERSION = "0.1.0" + class << self # display additional debug information (defaults to false) attr_accessor :verbose diff --git a/tool/sync_default_gems.rb b/tool/sync_default_gems.rb index 63e43964e0..f4e5a73381 100644 --- a/tool/sync_default_gems.rb +++ b/tool/sync_default_gems.rb @@ -29,6 +29,7 @@ # * https://github.com/ruby/rss # * https://github.com/ruby/irb # * https://github.com/ruby/sync +# * https://github.com/ruby/tracer # $repositories = { @@ -60,7 +61,8 @@ $repositories = { rexml: 'ruby/rexml', rss: 'ruby/rss', irb: 'ruby/irb', - sync: 'ruby/sync' + sync: 'ruby/sync', + tracer: 'ruby/tracer' } def sync_default_gems(gem) @@ -219,6 +221,11 @@ def sync_default_gems(gem) `cp -rf ../sync/lib/* lib` `cp -rf ../sync/test/thread test` `cp -f ../sync/sync.gemspec lib` + when "tracer" + `rm -rf lib/tracer.rb test/test_tracer.rb` + `cp -rf ../tracer/lib/* lib` + `cp -rf ../tracer/test/test_tracer.rb test` + `cp -f ../tracer/tracer.gemspec lib` when "rexml", "rss", "matrix", "irb", "csv" sync_lib gem else -- cgit v1.2.3