win32-api 1.6.0-universal-mingw32 → 1.6.1.beta1-universal-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES +4 -0
- data/Gemfile.lock +5 -5
- data/Rakefile +45 -19
- data/appveyor.yml +12 -0
- data/appveyor/build.cmd +3 -0
- data/lib/win32/api.rb +8 -0
- data/lib/win32/ruby21_32/win32/api.so +0 -0
- data/lib/win32/ruby21_64/win32/api.so +0 -0
- data/lib/win32/ruby22_32/win32/api.so +0 -0
- data/lib/win32/ruby22_64/win32/api.so +0 -0
- data/lib/win32/ruby23_32/win32/api.so +0 -0
- data/lib/win32/ruby23_64/win32/api.so +0 -0
- data/lib/win32/ruby24_32/win32/api.so +0 -0
- data/lib/win32/ruby24_64/win32/api.so +0 -0
- data/lib/win32/ruby2_32/win32/api.so +0 -0
- data/lib/win32/ruby2_64/win32/api.so +0 -0
- data/win32-api.gemspec +1 -1
- metadata +8 -341
- data/vendor/bundle/ruby/2.2.0/bin/devkit +0 -23
- data/vendor/bundle/ruby/2.2.0/bin/devkit.bat +0 -6
- data/vendor/bundle/ruby/2.2.0/bin/rake +0 -23
- data/vendor/bundle/ruby/2.2.0/bin/rake.bat +0 -6
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/CHANGELOG +0 -55
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/LICENSE +0 -339
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/README.md +0 -73
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/Rakefile +0 -8
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/colorize.gemspec +0 -35
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/lib/colorize.rb +0 -12
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/lib/colorize/class_methods.rb +0 -116
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/lib/colorize/instance_methods.rb +0 -135
- data/vendor/bundle/ruby/2.2.0/gems/colorize-0.7.7/test/test_colorize.rb +0 -161
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/Gemfile +0 -4
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/LICENSE.txt +0 -22
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/README.md +0 -34
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/Rakefile +0 -1
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/Rspec-example-matchers.txt +0 -184
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/bin/devkit +0 -87
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/devkit.gemspec +0 -27
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/lib/devkit.rb +0 -18
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/lib/devkit/core.rb +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/lib/devkit/identity.rb +0 -78
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/lib/devkit/ssh_identity.rb +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/lib/devkit/version.rb +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/spec/devkit/core_spec.rb +0 -46
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/spec/devkit/identity_spec.rb +0 -1
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/spec/devkit/ssh_identity_spec.rb +0 -1
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/spec/devkit_spec.rb +0 -5
- data/vendor/bundle/ruby/2.2.0/gems/devkit-0.1.0/spec/spec_helper.rb +0 -8
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/AUTHORS +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/COPYING +0 -339
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/Changelog.md +0 -415
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/Gemfile +0 -9
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/INSTALL +0 -59
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/LICENSE +0 -7
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/README.rdoc +0 -74
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/Rakefile +0 -30
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/TODO +0 -6
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/ansi_colors.rb +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/asking_for_arrays.rb +0 -18
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/basic_usage.rb +0 -75
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/color_scheme.rb +0 -32
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/get_character.rb +0 -12
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/limit.rb +0 -12
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/menus.rb +0 -65
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/overwrite.rb +0 -19
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/page_and_wrap.rb +0 -322
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/password.rb +0 -7
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/repeat_entry.rb +0 -21
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/trapping_eof.rb +0 -22
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/examples/using_readline.rb +0 -17
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/highline.gemspec +0 -37
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline.rb +0 -1048
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/color_scheme.rb +0 -134
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/compatibility.rb +0 -16
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/import.rb +0 -41
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/menu.rb +0 -381
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/question.rb +0 -480
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/simulate.rb +0 -48
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/style.rb +0 -192
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/lib/highline/version.rb +0 -4
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/setup.rb +0 -1360
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/site/highline.css +0 -65
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/site/images/logo.png +0 -0
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/site/index.html +0 -58
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/string_methods.rb +0 -32
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_color_scheme.rb +0 -96
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_highline.rb +0 -1402
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_import.rb +0 -52
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_menu.rb +0 -439
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_simulator.rb +0 -23
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_string_highline.rb +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/highline-1.7.8/test/tc_style.rb +0 -578
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/BSDL +0 -22
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/COPYING +0 -57
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/Gemfile +0 -9
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/LEGAL +0 -4
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/README.rdoc +0 -19
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/Rakefile +0 -16
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/benchmarks/bm_yhpg.rb +0 -59
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/benchmarks/helper.rb +0 -8
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/lib/power_assert.rb +0 -338
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/lib/power_assert/enable_tracepoint_events.rb +0 -82
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/lib/power_assert/version.rb +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/power_assert.gemspec +0 -23
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/test/helper.rb +0 -10
- data/vendor/bundle/ruby/2.2.0/gems/power_assert-0.3.0/test/test_power_assert.rb +0 -512
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/CONTRIBUTING.rdoc +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/History.rdoc +0 -719
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/MIT-LICENSE +0 -21
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/Manifest.txt +0 -154
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/README.rdoc +0 -157
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/Rakefile +0 -82
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/bin/rake +0 -33
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/command_line_usage.rdoc +0 -158
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/example/Rakefile1 +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/example/Rakefile2 +0 -35
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/example/a.c +0 -6
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/example/b.c +0 -6
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/example/main.c +0 -11
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/glossary.rdoc +0 -42
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/jamis.rb +0 -591
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/proto_rake.rdoc +0 -127
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/rake.1 +0 -141
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/rakefile.rdoc +0 -624
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/rational.rdoc +0 -151
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.4.14.rdoc +0 -23
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.4.15.rdoc +0 -35
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.5.0.rdoc +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.5.3.rdoc +0 -78
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.5.4.rdoc +0 -46
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.6.0.rdoc +0 -141
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.7.0.rdoc +0 -119
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.7.1.rdoc +0 -59
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.7.2.rdoc +0 -121
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.7.3.rdoc +0 -47
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.0.rdoc +0 -114
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.2.rdoc +0 -165
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.3.rdoc +0 -112
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.4.rdoc +0 -147
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.5.rdoc +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.6.rdoc +0 -37
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.8.7.rdoc +0 -55
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.0.rdoc +0 -112
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.1.rdoc +0 -52
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.2.2.rdoc +0 -55
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.2.rdoc +0 -49
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.3.rdoc +0 -102
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.4.rdoc +0 -60
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.5.rdoc +0 -55
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-0.9.6.rdoc +0 -64
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-10.0.0.rdoc +0 -178
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-10.0.1.rdoc +0 -58
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-10.0.2.rdoc +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-10.0.3.rdoc +0 -191
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/doc/release_notes/rake-10.1.0.rdoc +0 -61
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake.rb +0 -73
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/application.rb +0 -787
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/backtrace.rb +0 -23
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/clean.rb +0 -76
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/cloneable.rb +0 -16
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/contrib/compositepublisher.rb +0 -21
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/contrib/ftptools.rb +0 -137
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/contrib/sshpublisher.rb +0 -60
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/cpu_counter.rb +0 -120
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/default_loader.rb +0 -14
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/dsl_definition.rb +0 -194
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/early_time.rb +0 -21
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/file_creation_task.rb +0 -24
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/file_list.rb +0 -436
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/file_task.rb +0 -46
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/file_utils.rb +0 -123
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/invocation_chain.rb +0 -56
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/invocation_exception_mixin.rb +0 -16
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/late_time.rb +0 -17
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/linked_list.rb +0 -111
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/loaders/makefile.rb +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/multi_task.rb +0 -13
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/name_space.rb +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/packagetask.rb +0 -199
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/phony.rb +0 -15
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/private_reader.rb +0 -20
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/promise.rb +0 -99
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/pseudo_status.rb +0 -29
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/rake_test_loader.rb +0 -22
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/rule_recursion_overflow_error.rb +0 -20
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/scope.rb +0 -42
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/task.rb +0 -391
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/task_argument_error.rb +0 -7
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/task_arguments.rb +0 -102
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/task_manager.rb +0 -316
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/tasklib.rb +0 -11
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/testtask.rb +0 -204
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/thread_history_display.rb +0 -48
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/thread_pool.rb +0 -163
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/trace_output.rb +0 -22
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/version.rb +0 -7
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/lib/rake/win32.rb +0 -50
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/rakelib/test_times.rake +0 -25
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/file_creation.rb +0 -34
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/helper.rb +0 -134
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/support/rakefile_definitions.rb +0 -476
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/support/ruby_runner.rb +0 -34
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_private_reader.rb +0 -42
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake.rb +0 -40
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_application.rb +0 -659
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_application_options.rb +0 -468
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_backtrace.rb +0 -119
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_clean.rb +0 -61
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_cpu_counter.rb +0 -68
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_definitions.rb +0 -84
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_directory_task.rb +0 -76
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_dsl.rb +0 -40
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_early_time.rb +0 -31
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_file_creation_task.rb +0 -56
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_file_list.rb +0 -687
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_file_list_path_map.rb +0 -15
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_file_task.rb +0 -197
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_file_utils.rb +0 -318
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_ftp_file.rb +0 -74
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_functional.rb +0 -484
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_invocation_chain.rb +0 -64
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_late_time.rb +0 -18
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_linked_list.rb +0 -84
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_makefile_loader.rb +0 -46
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_multi_task.rb +0 -64
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_name_space.rb +0 -57
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_package_task.rb +0 -79
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_path_map.rb +0 -168
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_path_map_explode.rb +0 -34
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_path_map_partial.rb +0 -18
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_pseudo_status.rb +0 -21
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_rake_test_loader.rb +0 -20
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_reduce_compat.rb +0 -26
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_require.rb +0 -40
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_rules.rb +0 -388
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_scope.rb +0 -44
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_task.rb +0 -430
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_task_argument_parsing.rb +0 -119
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_task_arguments.rb +0 -134
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_task_manager.rb +0 -178
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_task_manager_argument_resolution.rb +0 -19
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_task_with_arguments.rb +0 -172
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_test_task.rb +0 -130
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_thread_pool.rb +0 -145
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_top_level_functions.rb +0 -71
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_rake_win32.rb +0 -72
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_thread_history_display.rb +0 -101
- data/vendor/bundle/ruby/2.2.0/gems/rake-11.1.2/test/test_trace_output.rb +0 -52
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/COPYING +0 -64
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/GPL +0 -339
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/LGPL +0 -502
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/PSFL +0 -271
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/README.md +0 -101
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/Rakefile +0 -71
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test-unit.rb +0 -34
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit.rb +0 -505
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/assertion-failed-error.rb +0 -25
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/assertions.rb +0 -2218
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/attribute-matcher.rb +0 -26
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/attribute.rb +0 -158
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/auto-runner-loader.rb +0 -17
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/autorunner.rb +0 -536
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/code-snippet-fetcher.rb +0 -58
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/collector.rb +0 -73
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/collector/descendant.rb +0 -19
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/collector/dir.rb +0 -108
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/collector/load.rb +0 -202
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/collector/objectspace.rb +0 -34
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/collector/xml.rb +0 -249
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/color-scheme.rb +0 -198
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/color.rb +0 -134
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/data.rb +0 -262
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/diff.rb +0 -746
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/error.rb +0 -158
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/exception-handler.rb +0 -82
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/failure.rb +0 -169
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/fault-location-detector.rb +0 -100
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/fixture.rb +0 -295
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/notification.rb +0 -136
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/omission.rb +0 -195
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/pending.rb +0 -154
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/priority.rb +0 -192
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/runner/console.rb +0 -59
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/runner/emacs.rb +0 -8
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/runner/xml.rb +0 -15
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/test-suite-creator.rb +0 -89
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/testcase.rb +0 -811
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/testresult.rb +0 -132
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/testsuite.rb +0 -175
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/console/outputlevel.rb +0 -15
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/console/testrunner.rb +0 -693
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/emacs/testrunner.rb +0 -49
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/testrunner.rb +0 -53
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/testrunnermediator.rb +0 -114
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/testrunnerutilities.rb +0 -41
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/ui/xml/testrunner.rb +0 -224
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/util/backtracefilter.rb +0 -59
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/util/method-owner-finder.rb +0 -28
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/util/observable.rb +0 -90
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/util/output.rb +0 -31
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/util/procwrapper.rb +0 -48
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/lib/test/unit/version.rb +0 -5
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/sample/adder.rb +0 -13
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/sample/subtracter.rb +0 -12
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/sample/test_adder.rb +0 -20
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/sample/test_subtracter.rb +0 -20
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/sample/test_user.rb +0 -23
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/collector/test-descendant.rb +0 -178
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/collector/test-load.rb +0 -442
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/collector/test_dir.rb +0 -406
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/collector/test_objectspace.rb +0 -100
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/header-label.csv +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/header-label.tsv +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/header.csv +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/header.tsv +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/no-header.csv +0 -2
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/no-header.tsv +0 -2
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/fixtures/plus.csv +0 -3
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/run-test.rb +0 -22
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-assertions.rb +0 -2160
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-attribute-matcher.rb +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-attribute.rb +0 -123
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-code-snippet.rb +0 -37
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-color-scheme.rb +0 -82
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-color.rb +0 -47
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-data.rb +0 -303
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-diff.rb +0 -518
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-emacs-runner.rb +0 -60
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-error.rb +0 -26
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-failure.rb +0 -33
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-fault-location-detector.rb +0 -163
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-fixture.rb +0 -713
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-notification.rb +0 -33
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-omission.rb +0 -81
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-pending.rb +0 -70
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-priority.rb +0 -173
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-test-case.rb +0 -1171
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-test-result.rb +0 -113
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-test-suite-creator.rb +0 -97
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/test-test-suite.rb +0 -150
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/testunit-test-util.rb +0 -31
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/ui/test_testrunmediator.rb +0 -20
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/util/test-method-owner-finder.rb +0 -38
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/util/test-output.rb +0 -11
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/util/test_backtracefilter.rb +0 -52
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/util/test_observable.rb +0 -102
- data/vendor/bundle/ruby/2.2.0/gems/test-unit-3.1.9/test/util/test_procwrapper.rb +0 -36
- data/vendor/bundle/ruby/2.2.0/specifications/colorize-0.7.7.gemspec +0 -38
- data/vendor/bundle/ruby/2.2.0/specifications/devkit-0.1.0.gemspec +0 -46
- data/vendor/bundle/ruby/2.2.0/specifications/highline-1.7.8.gemspec +0 -37
- data/vendor/bundle/ruby/2.2.0/specifications/power_assert-0.3.0.gemspec +0 -41
- data/vendor/bundle/ruby/2.2.0/specifications/rake-11.1.2.gemspec +0 -43
- data/vendor/bundle/ruby/2.2.0/specifications/test-unit-3.1.9.gemspec +0 -47
@@ -1,134 +0,0 @@
|
|
1
|
-
# color_scheme.rb
|
2
|
-
#
|
3
|
-
# Created by Jeremy Hinegardner on 2007-01-24
|
4
|
-
# Copyright 2007. All rights reserved
|
5
|
-
#
|
6
|
-
# This is Free Software. See LICENSE and COPYING for details
|
7
|
-
|
8
|
-
class HighLine
|
9
|
-
#
|
10
|
-
# ColorScheme objects encapsulate a named set of colors to be used in the
|
11
|
-
# HighLine.colors() method call. For example, by applying a ColorScheme that
|
12
|
-
# has a <tt>:warning</tt> color then the following could be used:
|
13
|
-
#
|
14
|
-
# colors("This is a warning", :warning)
|
15
|
-
#
|
16
|
-
# A ColorScheme contains named sets of HighLine color constants.
|
17
|
-
#
|
18
|
-
# Example: Instantiating a color scheme, applying it to HighLine,
|
19
|
-
# and using it:
|
20
|
-
#
|
21
|
-
# ft = HighLine::ColorScheme.new do |cs|
|
22
|
-
# cs[:headline] = [ :bold, :yellow, :on_black ]
|
23
|
-
# cs[:horizontal_line] = [ :bold, :white ]
|
24
|
-
# cs[:even_row] = [ :green ]
|
25
|
-
# cs[:odd_row] = [ :magenta ]
|
26
|
-
# end
|
27
|
-
#
|
28
|
-
# HighLine.color_scheme = ft
|
29
|
-
# say("<%= color('Headline', :headline) %>")
|
30
|
-
# say("<%= color('-'*20, :horizontal_line) %>")
|
31
|
-
# i = true
|
32
|
-
# ("A".."D").each do |row|
|
33
|
-
# if i then
|
34
|
-
# say("<%= color('#{row}', :even_row ) %>")
|
35
|
-
# else
|
36
|
-
# say("<%= color('#{row}', :odd_row) %>")
|
37
|
-
# end
|
38
|
-
# i = !i
|
39
|
-
# end
|
40
|
-
#
|
41
|
-
#
|
42
|
-
class ColorScheme
|
43
|
-
#
|
44
|
-
# Create an instance of HighLine::ColorScheme. The customization can
|
45
|
-
# happen as a passed in Hash or via the yielded block. Keys are
|
46
|
-
# converted to <tt>:symbols</tt> and values are converted to HighLine
|
47
|
-
# constants.
|
48
|
-
#
|
49
|
-
def initialize( h = nil )
|
50
|
-
@scheme = Hash.new
|
51
|
-
load_from_hash(h) unless h.nil?
|
52
|
-
yield self if block_given?
|
53
|
-
end
|
54
|
-
|
55
|
-
# Load multiple colors from key/value pairs.
|
56
|
-
def load_from_hash( h )
|
57
|
-
h.each_pair do |color_tag, constants|
|
58
|
-
self[color_tag] = constants
|
59
|
-
end
|
60
|
-
end
|
61
|
-
|
62
|
-
# Does this color scheme include the given tag name?
|
63
|
-
def include?( color_tag )
|
64
|
-
@scheme.keys.include?(to_symbol(color_tag))
|
65
|
-
end
|
66
|
-
|
67
|
-
# Allow the scheme to be accessed like a Hash.
|
68
|
-
def []( color_tag )
|
69
|
-
@scheme[to_symbol(color_tag)]
|
70
|
-
end
|
71
|
-
|
72
|
-
# Retrieve the original form of the scheme
|
73
|
-
def definition( color_tag )
|
74
|
-
style = @scheme[to_symbol(color_tag)]
|
75
|
-
style && style.list
|
76
|
-
end
|
77
|
-
|
78
|
-
# Retrieve the keys in the scheme
|
79
|
-
def keys
|
80
|
-
@scheme.keys
|
81
|
-
end
|
82
|
-
|
83
|
-
# Allow the scheme to be set like a Hash.
|
84
|
-
def []=( color_tag, constants )
|
85
|
-
@scheme[to_symbol(color_tag)] = HighLine::Style.new(:name=>color_tag.to_s.downcase.to_sym,
|
86
|
-
:list=>constants, :no_index=>true)
|
87
|
-
end
|
88
|
-
|
89
|
-
# Retrieve the color scheme hash (in original definition format)
|
90
|
-
def to_hash
|
91
|
-
@scheme.inject({}) { |hsh, pair| key, value = pair; hsh[key] = value.list; hsh }
|
92
|
-
end
|
93
|
-
|
94
|
-
|
95
|
-
private
|
96
|
-
|
97
|
-
# Return a normalized representation of a color name.
|
98
|
-
def to_symbol( t )
|
99
|
-
t.to_s.downcase
|
100
|
-
end
|
101
|
-
|
102
|
-
# Return a normalized representation of a color setting.
|
103
|
-
def to_constant( v )
|
104
|
-
v = v.to_s if v.is_a?(Symbol)
|
105
|
-
if v.is_a?(::String) then
|
106
|
-
HighLine.const_get(v.upcase)
|
107
|
-
else
|
108
|
-
v
|
109
|
-
end
|
110
|
-
end
|
111
|
-
end
|
112
|
-
|
113
|
-
# A sample ColorScheme.
|
114
|
-
class SampleColorScheme < ColorScheme
|
115
|
-
#
|
116
|
-
# Builds the sample scheme with settings for <tt>:critical</tt>,
|
117
|
-
# <tt>:error</tt>, <tt>:warning</tt>, <tt>:notice</tt>, <tt>:info</tt>,
|
118
|
-
# <tt>:debug</tt>, <tt>:row_even</tt>, and <tt>:row_odd</tt> colors.
|
119
|
-
#
|
120
|
-
def initialize( h = nil )
|
121
|
-
scheme = {
|
122
|
-
:critical => [ :yellow, :on_red ],
|
123
|
-
:error => [ :bold, :red ],
|
124
|
-
:warning => [ :bold, :yellow ],
|
125
|
-
:notice => [ :bold, :magenta ],
|
126
|
-
:info => [ :bold, :cyan ],
|
127
|
-
:debug => [ :bold, :green ],
|
128
|
-
:row_even => [ :cyan ],
|
129
|
-
:row_odd => [ :magenta ]
|
130
|
-
}
|
131
|
-
super(scheme)
|
132
|
-
end
|
133
|
-
end
|
134
|
-
end
|
@@ -1,16 +0,0 @@
|
|
1
|
-
unless STDIN.respond_to? :getbyte
|
2
|
-
class IO
|
3
|
-
alias_method :getbyte, :getc
|
4
|
-
end
|
5
|
-
|
6
|
-
class StringIO
|
7
|
-
alias_method :getbyte, :getc
|
8
|
-
end
|
9
|
-
end
|
10
|
-
|
11
|
-
unless "".respond_to? :each_line
|
12
|
-
# Not a perfect translation, but sufficient for our needs.
|
13
|
-
class String
|
14
|
-
alias_method :each_line, :each
|
15
|
-
end
|
16
|
-
end
|
@@ -1,41 +0,0 @@
|
|
1
|
-
# import.rb
|
2
|
-
#
|
3
|
-
# Created by James Edward Gray II on 2005-04-26.
|
4
|
-
# Copyright 2005 Gray Productions. All rights reserved.
|
5
|
-
#
|
6
|
-
# This is Free Software. See LICENSE and COPYING for details.
|
7
|
-
|
8
|
-
require "highline"
|
9
|
-
require "forwardable"
|
10
|
-
|
11
|
-
$terminal = HighLine.new
|
12
|
-
|
13
|
-
#
|
14
|
-
# <tt>require "highline/import"</tt> adds shortcut methods to Kernel, making
|
15
|
-
# agree(), ask(), choose() and say() globally available. This is handy for
|
16
|
-
# quick and dirty input and output. These methods use the HighLine object in
|
17
|
-
# the global variable <tt>$terminal</tt>, which is initialized to used
|
18
|
-
# <tt>$stdin</tt> and <tt>$stdout</tt> (you are free to change this).
|
19
|
-
# Otherwise, these methods are identical to their HighLine counterparts, see that
|
20
|
-
# class for detailed explanations.
|
21
|
-
#
|
22
|
-
module Kernel
|
23
|
-
extend Forwardable
|
24
|
-
def_delegators :$terminal, :agree, :ask, :choose, :say
|
25
|
-
end
|
26
|
-
|
27
|
-
class Object
|
28
|
-
#
|
29
|
-
# Tries this object as a _first_answer_ for a HighLine::Question. See that
|
30
|
-
# attribute for details.
|
31
|
-
#
|
32
|
-
# *Warning*: This Object will be passed to String() before set.
|
33
|
-
#
|
34
|
-
def or_ask( *args, &details )
|
35
|
-
ask(*args) do |question|
|
36
|
-
question.first_answer = String(self) unless nil?
|
37
|
-
|
38
|
-
details.call(question) unless details.nil?
|
39
|
-
end
|
40
|
-
end
|
41
|
-
end
|
@@ -1,381 +0,0 @@
|
|
1
|
-
# menu.rb
|
2
|
-
#
|
3
|
-
# Created by Gregory Thomas Brown on 2005-05-10.
|
4
|
-
# Copyright 2005. All rights reserved.
|
5
|
-
#
|
6
|
-
# This is Free Software. See LICENSE and COPYING for details.
|
7
|
-
|
8
|
-
require "highline/question"
|
9
|
-
|
10
|
-
class HighLine
|
11
|
-
#
|
12
|
-
# Menu objects encapsulate all the details of a call to HighLine.choose().
|
13
|
-
# Using the accessors and Menu.choice() and Menu.choices(), the block passed
|
14
|
-
# to HighLine.choose() can detail all aspects of menu display and control.
|
15
|
-
#
|
16
|
-
class Menu < Question
|
17
|
-
#
|
18
|
-
# Create an instance of HighLine::Menu. All customization is done
|
19
|
-
# through the passed block, which should call accessors and choice() and
|
20
|
-
# choices() as needed to define the Menu. Note that Menus are also
|
21
|
-
# Questions, so all that functionality is available to the block as
|
22
|
-
# well.
|
23
|
-
#
|
24
|
-
def initialize( )
|
25
|
-
#
|
26
|
-
# Initialize Question objects with ignored values, we'll
|
27
|
-
# adjust ours as needed.
|
28
|
-
#
|
29
|
-
super("Ignored", [ ], &nil) # avoiding passing the block along
|
30
|
-
|
31
|
-
@items = [ ]
|
32
|
-
@hidden_items = [ ]
|
33
|
-
@help = Hash.new("There's no help for that topic.")
|
34
|
-
|
35
|
-
@index = :number
|
36
|
-
@index_suffix = ". "
|
37
|
-
@select_by = :index_or_name
|
38
|
-
@flow = :rows
|
39
|
-
@list_option = nil
|
40
|
-
@header = nil
|
41
|
-
@prompt = "? "
|
42
|
-
@layout = :list
|
43
|
-
@shell = false
|
44
|
-
@nil_on_handled = false
|
45
|
-
|
46
|
-
# Override Questions responses, we'll set our own.
|
47
|
-
@responses = { }
|
48
|
-
# Context for action code.
|
49
|
-
@highline = nil
|
50
|
-
|
51
|
-
yield self if block_given?
|
52
|
-
|
53
|
-
init_help if @shell and not @help.empty?
|
54
|
-
end
|
55
|
-
|
56
|
-
#
|
57
|
-
# An _index_ to append to each menu item in display. See
|
58
|
-
# Menu.index=() for details.
|
59
|
-
#
|
60
|
-
attr_reader :index
|
61
|
-
#
|
62
|
-
# The String placed between an _index_ and a menu item. Defaults to
|
63
|
-
# ". ". Switches to " ", when _index_ is set to a String (like "-").
|
64
|
-
#
|
65
|
-
attr_accessor :index_suffix
|
66
|
-
#
|
67
|
-
# The _select_by_ attribute controls how the user is allowed to pick a
|
68
|
-
# menu item. The available choices are:
|
69
|
-
#
|
70
|
-
# <tt>:index</tt>:: The user is allowed to type the numerical
|
71
|
-
# or alphabetical index for their selection.
|
72
|
-
# <tt>:index_or_name</tt>:: Allows both methods from the
|
73
|
-
# <tt>:index</tt> option and the
|
74
|
-
# <tt>:name</tt> option.
|
75
|
-
# <tt>:name</tt>:: Menu items are selected by typing a portion
|
76
|
-
# of the item name that will be
|
77
|
-
# auto-completed.
|
78
|
-
#
|
79
|
-
attr_accessor :select_by
|
80
|
-
#
|
81
|
-
# This attribute is passed directly on as the mode to HighLine.list() by
|
82
|
-
# all the preset layouts. See that method for appropriate settings.
|
83
|
-
#
|
84
|
-
attr_accessor :flow
|
85
|
-
#
|
86
|
-
# This setting is passed on as the third parameter to HighLine.list()
|
87
|
-
# by all the preset layouts. See that method for details of its
|
88
|
-
# effects. Defaults to +nil+.
|
89
|
-
#
|
90
|
-
attr_accessor :list_option
|
91
|
-
#
|
92
|
-
# Used by all the preset layouts to display title and/or introductory
|
93
|
-
# information, when set. Defaults to +nil+.
|
94
|
-
#
|
95
|
-
attr_accessor :header
|
96
|
-
#
|
97
|
-
# Used by all the preset layouts to ask the actual question to fetch a
|
98
|
-
# menu selection from the user. Defaults to "? ".
|
99
|
-
#
|
100
|
-
attr_accessor :prompt
|
101
|
-
#
|
102
|
-
# An ERb _layout_ to use when displaying this Menu object. See
|
103
|
-
# Menu.layout=() for details.
|
104
|
-
#
|
105
|
-
attr_reader :layout
|
106
|
-
#
|
107
|
-
# When set to +true+, responses are allowed to be an entire line of
|
108
|
-
# input, including details beyond the command itself. Only the first
|
109
|
-
# "word" of input will be matched against the menu choices, but both the
|
110
|
-
# command selected and the rest of the line will be passed to provided
|
111
|
-
# action blocks. Defaults to +false+.
|
112
|
-
#
|
113
|
-
attr_accessor :shell
|
114
|
-
#
|
115
|
-
# When +true+, any selected item handled by provided action code will
|
116
|
-
# return +nil+, instead of the results to the action code. This may
|
117
|
-
# prove handy when dealing with mixed menus where only the names of
|
118
|
-
# items without any code (and +nil+, of course) will be returned.
|
119
|
-
# Defaults to +false+.
|
120
|
-
#
|
121
|
-
attr_accessor :nil_on_handled
|
122
|
-
|
123
|
-
#
|
124
|
-
# Adds _name_ to the list of available menu items. Menu items will be
|
125
|
-
# displayed in the order they are added.
|
126
|
-
#
|
127
|
-
# An optional _action_ can be associated with this name and if provided,
|
128
|
-
# it will be called if the item is selected. The result of the method
|
129
|
-
# will be returned, unless _nil_on_handled_ is set (when you would get
|
130
|
-
# +nil+ instead). In _shell_ mode, a provided block will be passed the
|
131
|
-
# command chosen and any details that followed the command. Otherwise,
|
132
|
-
# just the command is passed. The <tt>@highline</tt> variable is set to
|
133
|
-
# the current HighLine context before the action code is called and can
|
134
|
-
# thus be used for adding output and the like.
|
135
|
-
#
|
136
|
-
def choice( name, help = nil, &action )
|
137
|
-
@items << [name, action]
|
138
|
-
|
139
|
-
@help[name.to_s.downcase] = help unless help.nil?
|
140
|
-
update_responses # rebuild responses based on our settings
|
141
|
-
end
|
142
|
-
|
143
|
-
#
|
144
|
-
# A shortcut for multiple calls to the sister method choice(). <b>Be
|
145
|
-
# warned:</b> An _action_ set here will apply to *all* provided
|
146
|
-
# _names_. This is considered to be a feature, so you can easily
|
147
|
-
# hand-off interface processing to a different chunk of code.
|
148
|
-
#
|
149
|
-
def choices( *names, &action )
|
150
|
-
names.each { |n| choice(n, &action) }
|
151
|
-
end
|
152
|
-
|
153
|
-
# Identical to choice(), but the item will not be listed for the user.
|
154
|
-
def hidden( name, help = nil, &action )
|
155
|
-
@hidden_items << [name, action]
|
156
|
-
|
157
|
-
@help[name.to_s.downcase] = help unless help.nil?
|
158
|
-
end
|
159
|
-
|
160
|
-
#
|
161
|
-
# Sets the indexing style for this Menu object. Indexes are appended to
|
162
|
-
# menu items, when displayed in list form. The available settings are:
|
163
|
-
#
|
164
|
-
# <tt>:number</tt>:: Menu items will be indexed numerically, starting
|
165
|
-
# with 1. This is the default method of indexing.
|
166
|
-
# <tt>:letter</tt>:: Items will be indexed alphabetically, starting
|
167
|
-
# with a.
|
168
|
-
# <tt>:none</tt>:: No index will be appended to menu items.
|
169
|
-
# <i>any String</i>:: Will be used as the literal _index_.
|
170
|
-
#
|
171
|
-
# Setting the _index_ to <tt>:none</tt> or a literal String also adjusts
|
172
|
-
# _index_suffix_ to a single space and _select_by_ to <tt>:name</tt>.
|
173
|
-
# Because of this, you should make a habit of setting the _index_ first.
|
174
|
-
#
|
175
|
-
def index=( style )
|
176
|
-
@index = style
|
177
|
-
|
178
|
-
# Default settings.
|
179
|
-
if @index == :none or @index.is_a?(::String)
|
180
|
-
@index_suffix = " "
|
181
|
-
@select_by = :name
|
182
|
-
end
|
183
|
-
end
|
184
|
-
|
185
|
-
#
|
186
|
-
# Initializes the help system by adding a <tt>:help</tt> choice, some
|
187
|
-
# action code, and the default help listing.
|
188
|
-
#
|
189
|
-
def init_help( )
|
190
|
-
return if @items.include?(:help)
|
191
|
-
|
192
|
-
topics = @help.keys.sort
|
193
|
-
help_help = @help.include?("help") ? @help["help"] :
|
194
|
-
"This command will display helpful messages about " +
|
195
|
-
"functionality, like this one. To see the help for " +
|
196
|
-
"a specific topic enter:\n\thelp [TOPIC]\nTry asking " +
|
197
|
-
"for help on any of the following:\n\n" +
|
198
|
-
"<%= list(#{topics.inspect}, :columns_across) %>"
|
199
|
-
choice(:help, help_help) do |command, topic|
|
200
|
-
topic.strip!
|
201
|
-
topic.downcase!
|
202
|
-
if topic.empty?
|
203
|
-
@highline.say(@help["help"])
|
204
|
-
else
|
205
|
-
@highline.say("= #{topic}\n\n#{@help[topic]}")
|
206
|
-
end
|
207
|
-
end
|
208
|
-
end
|
209
|
-
|
210
|
-
#
|
211
|
-
# Used to set help for arbitrary topics. Use the topic <tt>"help"</tt>
|
212
|
-
# to override the default message.
|
213
|
-
#
|
214
|
-
def help( topic, help )
|
215
|
-
@help[topic] = help
|
216
|
-
end
|
217
|
-
|
218
|
-
#
|
219
|
-
# Setting a _layout_ with this method also adjusts some other attributes
|
220
|
-
# of the Menu object, to ideal defaults for the chosen _layout_. To
|
221
|
-
# account for that, you probably want to set a _layout_ first in your
|
222
|
-
# configuration block, if needed.
|
223
|
-
#
|
224
|
-
# Accepted settings for _layout_ are:
|
225
|
-
#
|
226
|
-
# <tt>:list</tt>:: The default _layout_. The _header_ if set
|
227
|
-
# will appear at the top on its own line with
|
228
|
-
# a trailing colon. Then the list of menu
|
229
|
-
# items will follow. Finally, the _prompt_
|
230
|
-
# will be used as the ask()-like question.
|
231
|
-
# <tt>:one_line</tt>:: A shorter _layout_ that fits on one line.
|
232
|
-
# The _header_ comes first followed by a
|
233
|
-
# colon and spaces, then the _prompt_ with menu
|
234
|
-
# items between trailing parenthesis.
|
235
|
-
# <tt>:menu_only</tt>:: Just the menu items, followed up by a likely
|
236
|
-
# short _prompt_.
|
237
|
-
# <i>any ERb String</i>:: Will be taken as the literal _layout_. This
|
238
|
-
# String can access <tt>@header</tt>,
|
239
|
-
# <tt>@menu</tt> and <tt>@prompt</tt>, but is
|
240
|
-
# otherwise evaluated in the typical HighLine
|
241
|
-
# context, to provide access to utilities like
|
242
|
-
# HighLine.list() primarily.
|
243
|
-
#
|
244
|
-
# If set to either <tt>:one_line</tt>, or <tt>:menu_only</tt>, _index_
|
245
|
-
# will default to <tt>:none</tt> and _flow_ will default to
|
246
|
-
# <tt>:inline</tt>.
|
247
|
-
#
|
248
|
-
def layout=( new_layout )
|
249
|
-
@layout = new_layout
|
250
|
-
|
251
|
-
# Default settings.
|
252
|
-
case @layout
|
253
|
-
when :one_line, :menu_only
|
254
|
-
self.index = :none
|
255
|
-
@flow = :inline
|
256
|
-
end
|
257
|
-
end
|
258
|
-
|
259
|
-
#
|
260
|
-
# This method returns all possible options for auto-completion, based
|
261
|
-
# on the settings of _index_ and _select_by_.
|
262
|
-
#
|
263
|
-
def options( )
|
264
|
-
# add in any hidden menu commands
|
265
|
-
@items.concat(@hidden_items)
|
266
|
-
|
267
|
-
by_index = if @index == :letter
|
268
|
-
l_index = "`"
|
269
|
-
@items.map { "#{l_index.succ!}" }
|
270
|
-
else
|
271
|
-
(1 .. @items.size).collect { |s| String(s) }
|
272
|
-
end
|
273
|
-
by_name = @items.collect { |c| c.first }
|
274
|
-
|
275
|
-
case @select_by
|
276
|
-
when :index then
|
277
|
-
by_index
|
278
|
-
when :name
|
279
|
-
by_name
|
280
|
-
else
|
281
|
-
by_index + by_name
|
282
|
-
end
|
283
|
-
ensure
|
284
|
-
# make sure the hidden items are removed, before we return
|
285
|
-
@items.slice!(@items.size - @hidden_items.size, @hidden_items.size)
|
286
|
-
end
|
287
|
-
|
288
|
-
#
|
289
|
-
# This method processes the auto-completed user selection, based on the
|
290
|
-
# rules for this Menu object. If an action was provided for the
|
291
|
-
# selection, it will be executed as described in Menu.choice().
|
292
|
-
#
|
293
|
-
def select( highline_context, selection, details = nil )
|
294
|
-
# add in any hidden menu commands
|
295
|
-
@items.concat(@hidden_items)
|
296
|
-
|
297
|
-
# Find the selected action.
|
298
|
-
name, action = if selection =~ /^\d+$/
|
299
|
-
@items[selection.to_i - 1]
|
300
|
-
else
|
301
|
-
l_index = "`"
|
302
|
-
index = @items.map { "#{l_index.succ!}" }.index(selection)
|
303
|
-
@items.find { |c| c.first == selection } or @items[index]
|
304
|
-
end
|
305
|
-
|
306
|
-
# Run or return it.
|
307
|
-
if not action.nil?
|
308
|
-
@highline = highline_context
|
309
|
-
if @shell
|
310
|
-
result = action.call(name, details)
|
311
|
-
else
|
312
|
-
result = action.call(name)
|
313
|
-
end
|
314
|
-
@nil_on_handled ? nil : result
|
315
|
-
elsif action.nil?
|
316
|
-
name
|
317
|
-
else
|
318
|
-
nil
|
319
|
-
end
|
320
|
-
ensure
|
321
|
-
# make sure the hidden items are removed, before we return
|
322
|
-
@items.slice!(@items.size - @hidden_items.size, @hidden_items.size)
|
323
|
-
end
|
324
|
-
|
325
|
-
#
|
326
|
-
# Allows Menu objects to pass as Arrays, for use with HighLine.list().
|
327
|
-
# This method returns all menu items to be displayed, complete with
|
328
|
-
# indexes.
|
329
|
-
#
|
330
|
-
def to_ary( )
|
331
|
-
case @index
|
332
|
-
when :number
|
333
|
-
@items.map { |c| "#{@items.index(c) + 1}#{@index_suffix}#{c.first}" }
|
334
|
-
when :letter
|
335
|
-
l_index = "`"
|
336
|
-
@items.map { |c| "#{l_index.succ!}#{@index_suffix}#{c.first}" }
|
337
|
-
when :none
|
338
|
-
@items.map { |c| "#{c.first}" }
|
339
|
-
else
|
340
|
-
@items.map { |c| "#{index}#{@index_suffix}#{c.first}" }
|
341
|
-
end
|
342
|
-
end
|
343
|
-
|
344
|
-
#
|
345
|
-
# Allows Menu to behave as a String, just like Question. Returns the
|
346
|
-
# _layout_ to be rendered, which is used by HighLine.say().
|
347
|
-
#
|
348
|
-
def to_s( )
|
349
|
-
case @layout
|
350
|
-
when :list
|
351
|
-
'<%= if @header.nil? then '' else "#{@header}:\n" end %>' +
|
352
|
-
"<%= list( @menu, #{@flow.inspect},
|
353
|
-
#{@list_option.inspect} ) %>" +
|
354
|
-
"<%= @prompt %>"
|
355
|
-
when :one_line
|
356
|
-
'<%= if @header.nil? then '' else "#{@header}: " end %>' +
|
357
|
-
"<%= @prompt %>" +
|
358
|
-
"(<%= list( @menu, #{@flow.inspect},
|
359
|
-
#{@list_option.inspect} ) %>)" +
|
360
|
-
"<%= @prompt[/\s*$/] %>"
|
361
|
-
when :menu_only
|
362
|
-
"<%= list( @menu, #{@flow.inspect},
|
363
|
-
#{@list_option.inspect} ) %><%= @prompt %>"
|
364
|
-
else
|
365
|
-
@layout
|
366
|
-
end
|
367
|
-
end
|
368
|
-
|
369
|
-
#
|
370
|
-
# This method will update the intelligent responses to account for
|
371
|
-
# Menu specific differences. Calls the superclass' (Question's)
|
372
|
-
# build_responses method, overriding its default arguments to specify
|
373
|
-
# 'options' will be used to populate choice lists, and that
|
374
|
-
# the newly built hash will predominate over the preexisting hash
|
375
|
-
# for any keys that are the same.
|
376
|
-
#
|
377
|
-
def update_responses( )
|
378
|
-
build_responses(options, true)
|
379
|
-
end
|
380
|
-
end
|
381
|
-
end
|