tagen 2.0.0 → 2.0.1

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/.gitignore CHANGED
@@ -1,6 +1,6 @@
1
1
  /tags
2
-
3
2
  /*.gem
4
3
  /Gemfile
5
4
  /spec/tmp/*
6
5
  /.yardoc
6
+ .rbx
@@ -0,0 +1,21 @@
1
+ ## 2.0.1 (Sep 9, 2012)
2
+
3
+ Bugfixes
4
+
5
+ - Fix 'activesupport' dependency error in gemspec
6
+
7
+ ## 2.0.0 (Aug 29, 2012)
8
+
9
+ Improvements
10
+
11
+ - Based on `active_support` ([@gutenye][])
12
+ - Support `rubinius` version
13
+
14
+ Changes
15
+
16
+ - Remove `PyFormat`, `Array#extract_extend_options[!]`
17
+ - Change `Time::Detal` to `Numberic#time_humanize`
18
+
19
+
20
+ <!--- The following link definition list is generated by PimpMyChangelog --->
21
+ [@gutenye]: https://github.com/gutenye
@@ -1,13 +1,29 @@
1
1
  GEM
2
- remote: http://rubygems.org/
2
+ remote: https://rubygems.org/
3
3
  specs:
4
4
  activesupport (3.2.8)
5
5
  i18n (~> 0.6)
6
6
  multi_json (~> 1.0)
7
7
  diff-lcs (1.1.3)
8
+ ffi (1.1.5)
9
+ guard (1.3.2)
10
+ listen (>= 0.4.2)
11
+ thor (>= 0.14.6)
12
+ guard-rspec (1.2.1)
13
+ guard (>= 1.1)
8
14
  i18n (0.6.0)
15
+ listen (0.4.7)
16
+ rb-fchange (~> 0.0.5)
17
+ rb-fsevent (~> 0.9.1)
18
+ rb-inotify (~> 0.8.8)
9
19
  multi_json (1.3.6)
10
20
  pd (1.1.0)
21
+ pimpmychangelog (0.0.3)
22
+ rb-fchange (0.0.5)
23
+ ffi
24
+ rb-fsevent (0.9.1)
25
+ rb-inotify (0.8.8)
26
+ ffi (>= 0.5.0)
11
27
  rspec (2.11.0)
12
28
  rspec-core (~> 2.11.0)
13
29
  rspec-expectations (~> 2.11.0)
@@ -16,13 +32,15 @@ GEM
16
32
  rspec-expectations (2.11.2)
17
33
  diff-lcs (~> 1.1.3)
18
34
  rspec-mocks (2.11.2)
19
- watchr (0.7)
35
+ thor (0.16.0)
20
36
 
21
37
  PLATFORMS
22
38
  ruby
23
39
 
24
40
  DEPENDENCIES
25
- activesupport (~> 3.2.8)
41
+ activesupport
42
+ guard
43
+ guard-rspec
26
44
  pd
45
+ pimpmychangelog
27
46
  rspec
28
- watchr
@@ -0,0 +1,5 @@
1
+ guard 'rspec', :version => 2 do
2
+ watch(%r{^spec/.+_spec\.rb$})
3
+ watch(%r{^lib/(.+)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" }
4
+ watch('spec/spec_helper.rb') { "spec" }
5
+ end
data/README.md CHANGED
@@ -1,13 +1,14 @@
1
- # Tagen, a core and extra extension for Ruby [![Build Status](https://secure.travis-ci.org/GutenYe/tagen.png)](http://travis-ci.org/GutenYe/tagen)
1
+ Tagen, a core and extra extension for Ruby [![Build Status](https://secure.travis-ci.org/GutenYe/tagen.png)](http://travis-ci.org/GutenYe/tagen)
2
+ =======
2
3
 
3
4
  | | |
4
5
  |----------------|-----------------------------------------|
5
6
  | Homepage: | https://github.com/GutenYe/tagen |
6
- | Author: | Guten |
7
+ | Author: | Guten Ye |
7
8
  | License: | MIT LICENSE |
8
9
  | Documentation: | https://github.com/GutenYe/tagen/wiki |
9
10
  | Issue Tracker: | https://github.com/GutenYe/tagen/issues |
10
- | Versions: | Ruby 1.9.3, Rubinius |
11
+ | Ruby Versions: | Ruby 1.9.3, Rubinius |
11
12
 
12
13
  It based on "active_support", but it focus on generic ruby programming.
13
14
 
@@ -26,23 +27,29 @@ Load All Core Extensions
26
27
 
27
28
  require "tagen/core"
28
29
 
29
-
30
30
  Install
31
31
  ----------
32
32
 
33
33
  gem install tagen
34
34
 
35
+ Development [![Dependency Status](https://gemnasium.com/GutenYe/tagen.png?branch=master)](https://gemnasium.com/GutenYe/tagen) [![Code Climate](https://codeclimate.com/badge.png)](https://codeclimate.com/github/GutenYe/tagen)
36
+ ===========
37
+
35
38
  Contributing
36
39
  -------------
37
40
 
38
- * Feel free to join the project and make contributions (by submitting a pull request)
39
- * Submit any bugs/features/ideas to github issue tracker
41
+ * Submit any bugs/features/ideas to github issue tracker.
42
+
43
+ Pull requests are very welcome! Please try to follow these simple rules if applicable:
44
+
45
+ * Please create a topic branch for every separate change you make.
46
+ * Make sure your patches are well tested. All specs run with `rake test:portability` must pass.
40
47
  * Coding Style Guide: https://gist.github.com/1105334
41
48
 
42
49
  Contributors
43
50
  ------------
44
51
 
45
- * [contributors](https://github.com/GutenYe/tagen/contributors)
52
+ [https://github.com/GutenYe/tagen/contributors](https://github.com/GutenYe/tagen/contributors)
46
53
 
47
54
  Resources
48
55
  ---------
data/Rakefile CHANGED
@@ -1,4 +1,7 @@
1
1
  require "rbconfig"
2
+
3
+ PROJECT = "tagen"
4
+
2
5
  sudo = Process.pid != 0 && RbConfig::CONFIG["host_os"] !~ /mswin|mingw/ ? "sudo" : ""
3
6
 
4
7
  desc "build a gem file"
@@ -16,16 +19,45 @@ task :install do
16
19
  run "rm *.gem"
17
20
  end
18
21
 
19
- desc "autotest with watchr"
22
+ desc "run guard"
20
23
  task :test do
21
- run "watchr tagen.watchr"
24
+ run "bundle exec guard -c -n f"
22
25
  end
23
26
 
24
- desc "testing the libraray"
25
27
  namespace :test do
28
+ desc "testing the libraray"
26
29
  task :all do
27
- run "rspec spec"
30
+ run "bundle exec rspec spec"
28
31
  end
32
+
33
+ desc "Run all specs on multiple ruby versions (requires rvm)"
34
+ task :portability do
35
+ require "yaml"
36
+
37
+ travis_config_file = File.expand_path("../.travis.yml", __FILE__)
38
+ begin
39
+ travis_options ||= YAML::load_file(travis_config_file)
40
+ rescue => ex
41
+ puts "Travis config file '#{travis_config_file}' could not be found: #{ex.message}"
42
+ return
43
+ end
44
+
45
+ travis_options['rvm'].each do |version|
46
+ system <<-BASH
47
+ bash -c 'source ~/.rvm/scripts/rvm;
48
+ rvm #{version};
49
+ ruby_version_string_size=`ruby -v | wc -m`
50
+ echo;
51
+ for ((c=1; c<$ruby_version_string_size; c++)); do echo -n "="; done
52
+ echo;
53
+ echo "`ruby -v`";
54
+ for ((c=1; c<$ruby_version_string_size; c++)); do echo -n "="; done
55
+ echo;
56
+ bundle install;
57
+ bundle exec rspec spec 2>&1;'
58
+ BASH
59
+ end
60
+ end
29
61
  end
30
62
 
31
63
  desc "run yard server --reload"
@@ -38,7 +70,31 @@ task :clean do
38
70
  run "rm *.gem"
39
71
  end
40
72
 
73
+ desc "rewrite gemspec with add_dependency from Gemfile"
74
+ task :gemspec do
75
+ require "bundler"
76
+ gemspec = "#{PROJECT}.gemspec"
77
+
78
+ deps = Bundler.definition.dependencies.find_all{|v|
79
+ v.groups.include? :default
80
+ }
81
+
82
+ deps = deps.map {|dep|
83
+ list = [dep.name] + dep.requirements_list
84
+ "\ts.add_dependency #{list.map(&:inspect).join(', ')}\n"
85
+ }
86
+
87
+ lines = File.read(gemspec).lines.to_a
88
+ idx = lines.find_index{|v| v =~ /s\.add_dependency/} || -2
89
+ lines.delete_if{|v| v =~ /s\.add_dependency/}
90
+ lines.insert(idx, *deps)
91
+
92
+ File.write(gemspec, lines.join(""))
93
+ end
94
+
41
95
  def run cmd
42
96
  puts cmd
43
97
  system cmd
44
98
  end
99
+
100
+
@@ -1,3 +1,3 @@
1
1
  module Tagen
2
- VERSION = "2.0.0"
2
+ VERSION = "2.0.1"
3
3
  end
@@ -16,5 +16,5 @@ a lightweight core and extra extensions for Ruby.
16
16
  s.files = `git ls-files`.split("\n")
17
17
 
18
18
  s.add_dependency "pd"
19
- s.add_dependency "activesupport", "~>3.2.8"
19
+ s.add_dependency "activesupport"
20
20
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tagen
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-08-29 00:00:00.000000000 Z
12
+ date: 2012-09-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: pd
@@ -32,17 +32,17 @@ dependencies:
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  none: false
34
34
  requirements:
35
- - - ~>
35
+ - - ! '>='
36
36
  - !ruby/object:Gem::Version
37
- version: 3.2.8
37
+ version: '0'
38
38
  type: :runtime
39
39
  prerelease: false
40
40
  version_requirements: !ruby/object:Gem::Requirement
41
41
  none: false
42
42
  requirements:
43
- - - ~>
43
+ - - ! '>='
44
44
  - !ruby/object:Gem::Version
45
- version: 3.2.8
45
+ version: '0'
46
46
  description: ! "a lightweight core and extra extensions for Ruby. \n"
47
47
  email: ywzhaifei@gmail.com
48
48
  executables: []
@@ -53,9 +53,10 @@ files:
53
53
  - .rspec
54
54
  - .travis.yml
55
55
  - .yardopts
56
- - CHANGELOG
56
+ - CHANGELOG.md
57
57
  - Gemfile
58
58
  - Gemfile.lock
59
+ - Guardfile
59
60
  - README.md
60
61
  - Rakefile
61
62
  - benchmark/a.rb
@@ -112,7 +113,6 @@ files:
112
113
  - spec/tagen/socket_spec.rb
113
114
  - spec/tagen/uri_spec.rb
114
115
  - tagen.gemspec
115
- - tagen.watchr
116
116
  homepage: http://github.com/GutenYe/tagen
117
117
  licenses: []
118
118
  post_install_message:
data/CHANGELOG DELETED
@@ -1,6 +0,0 @@
1
- *tagen 2.0.0 (Aug 28, 2012)*
2
- * based on 'active_support'
3
- * support 'rubinius' version
4
-
5
- * remove 'PyFormat', 'Array#extract_extend_options[!]'
6
- * change 'Time::Detal' to 'Numberic#time_humanize'
@@ -1,21 +0,0 @@
1
- # lib/**/*.rb
2
- watch %r~lib/(.*)\.rb~ do |m|
3
- test "spec/#{m[1]}_spec.rb"
4
- end
5
-
6
- # spec/**/*_spec.rb
7
- watch %r~spec/.*_spec\.rb~ do |m|
8
- test m[0]
9
- end
10
-
11
- # Ctrl-\
12
- Signal.trap('QUIT') do
13
- puts "--- Running all tests ---\n\n"
14
- test "spec"
15
- end
16
-
17
- def test path
18
- cmd = "rspec #{path}"
19
- puts cmd
20
- system cmd
21
- end