simple_progressbar 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.2
1
+ 0.1.3
@@ -3,6 +3,8 @@ class SimpleProgressbar
3
3
  def show(title, &block)
4
4
  print title + " "
5
5
  start_progress
6
+ # thanks to http://www.dcmanges.com/blog/ruby-dsls-instance-eval-with-delegation
7
+ @self_before_instance_eval = eval "self", block.binding
6
8
  instance_eval(&block)
7
9
  finish_progress
8
10
  end
@@ -12,6 +14,10 @@ class SimpleProgressbar
12
14
  render_progress(percent)
13
15
  end
14
16
 
17
+ def method_missing(method, *args, &block)
18
+ @self_before_instance_eval.send method, *args, &block
19
+ end
20
+
15
21
  private
16
22
 
17
23
  def render_progress(percent)
@@ -34,4 +40,4 @@ class SimpleProgressbar
34
40
  def finish_progress
35
41
  puts
36
42
  end
37
- end
43
+ end
@@ -1,48 +1,46 @@
1
1
  # Generated by jeweler
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{simple_progressbar}
8
- s.version = "0.1.2"
8
+ s.version = "0.1.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Bodo Tasche"]
12
- s.date = %q{2010-04-21}
12
+ s.date = %q{2010-12-30}
13
13
  s.description = %q{A progressbar for the terminal. Handy for little scripts.}
14
14
  s.email = %q{bodo@bitboxer.de}
15
15
  s.extra_rdoc_files = [
16
16
  "LICENSE",
17
- "README.rdoc"
17
+ "README.rdoc"
18
18
  ]
19
19
  s.files = [
20
20
  ".document",
21
- ".gitignore",
22
- "LICENSE",
23
- "README.rdoc",
24
- "Rakefile",
25
- "VERSION",
26
- "lib/simple_progressbar.rb",
27
- "simple_progressbar.gemspec",
28
- "test/helper.rb",
29
- "test/test_simple_progressbar.rb"
21
+ "LICENSE",
22
+ "README.rdoc",
23
+ "Rakefile",
24
+ "VERSION",
25
+ "lib/simple_progressbar.rb",
26
+ "simple_progressbar.gemspec",
27
+ "test/helper.rb",
28
+ "test/test_simple_progressbar.rb"
30
29
  ]
31
30
  s.homepage = %q{http://github.com/bitboxer/simple_progressbar}
32
- s.rdoc_options = ["--charset=UTF-8"]
33
31
  s.require_paths = ["lib"]
34
- s.rubygems_version = %q{1.3.6}
32
+ s.rubygems_version = %q{1.3.7}
35
33
  s.summary = %q{A simple progressbar}
36
34
  s.test_files = [
37
35
  "test/helper.rb",
38
- "test/test_simple_progressbar.rb"
36
+ "test/test_simple_progressbar.rb"
39
37
  ]
40
38
 
41
39
  if s.respond_to? :specification_version then
42
40
  current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
43
41
  s.specification_version = 3
44
42
 
45
- if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
43
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
46
44
  s.add_development_dependency(%q<thoughtbot-shoulda>, [">= 0"])
47
45
  else
48
46
  s.add_dependency(%q<thoughtbot-shoulda>, [">= 0"])
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 1
8
- - 2
9
- version: 0.1.2
8
+ - 3
9
+ version: 0.1.3
10
10
  platform: ruby
11
11
  authors:
12
12
  - Bodo Tasche
@@ -14,13 +14,14 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-04-21 00:00:00 +02:00
17
+ date: 2010-12-30 00:00:00 +01:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: thoughtbot-shoulda
22
22
  prerelease: false
23
23
  requirement: &id001 !ruby/object:Gem::Requirement
24
+ none: false
24
25
  requirements:
25
26
  - - ">="
26
27
  - !ruby/object:Gem::Version
@@ -40,7 +41,6 @@ extra_rdoc_files:
40
41
  - README.rdoc
41
42
  files:
42
43
  - .document
43
- - .gitignore
44
44
  - LICENSE
45
45
  - README.rdoc
46
46
  - Rakefile
@@ -54,11 +54,12 @@ homepage: http://github.com/bitboxer/simple_progressbar
54
54
  licenses: []
55
55
 
56
56
  post_install_message:
57
- rdoc_options:
58
- - --charset=UTF-8
57
+ rdoc_options: []
58
+
59
59
  require_paths:
60
60
  - lib
61
61
  required_ruby_version: !ruby/object:Gem::Requirement
62
+ none: false
62
63
  requirements:
63
64
  - - ">="
64
65
  - !ruby/object:Gem::Version
@@ -66,6 +67,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
66
67
  - 0
67
68
  version: "0"
68
69
  required_rubygems_version: !ruby/object:Gem::Requirement
70
+ none: false
69
71
  requirements:
70
72
  - - ">="
71
73
  - !ruby/object:Gem::Version
@@ -75,7 +77,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
75
77
  requirements: []
76
78
 
77
79
  rubyforge_project:
78
- rubygems_version: 1.3.6
80
+ rubygems_version: 1.3.7
79
81
  signing_key:
80
82
  specification_version: 3
81
83
  summary: A simple progressbar
data/.gitignore DELETED
@@ -1,21 +0,0 @@
1
- ## MAC OS
2
- .DS_Store
3
-
4
- ## TEXTMATE
5
- *.tmproj
6
- tmtags
7
-
8
- ## EMACS
9
- *~
10
- \#*
11
- .\#*
12
-
13
- ## VIM
14
- *.swp
15
-
16
- ## PROJECT::GENERAL
17
- coverage
18
- rdoc
19
- pkg
20
-
21
- ## PROJECT::SPECIFIC