rim 2.1.0 → 2.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3584fd8b1f8edaba64ad5898875ffba5a1246a58
4
- data.tar.gz: f4a37986299c3eb521a76c1ad1ff3b0c1a9d81b8
3
+ metadata.gz: db109798d47e515d75644d53362ae3a3458bce11
4
+ data.tar.gz: 6e7d5ea38d7850dbbffa7715b32159a8e3fca91d
5
5
  SHA512:
6
- metadata.gz: 00a19fb439a66a8570a538c190088dcd04f771052016075fe0a4a7c04f0f8e34e0e4ffbbf19bfe7299219db2684ed42c23349b84bb2f25e94a3300a7a07a1ad6
7
- data.tar.gz: e6d3516b60326e820a87fd9032cf73eca4bf25c56b1596fe6e857ad4e07dc7d905ddec77ae27c9410d65eb4266ad2323dd3f6e59837e5e64bf22b68700707eb3
6
+ metadata.gz: bd4d1233a45b41163cc6dd951c21113b993bc36a45caac87842236523ef089000fd92a3f25bc3382c67dc712283fcbdcc97916313390f5758c32a36222bda295
7
+ data.tar.gz: e2403c6f6d86df13407b862deb25fa26c9eee7cf161075b2a18b3c71d6ef7df1a1da4c02de8b04692b662bfbe2a23a885885106a320a47dd93b0effc8a57f273
data/Changelog CHANGED
@@ -1,3 +1,7 @@
1
+ 2.2.0
2
+ Renaming task check_version -> version:check.
3
+ New options aspell_encoding and aspell_word_list.
4
+
1
5
  2.1.0
2
6
  New module rim/tire to load a good set of defaults.
3
7
  Expand FileList instances in info task.
@@ -43,7 +47,7 @@ Make git tasks independent from current
43
47
  locale and push tags.
44
48
 
45
49
  1.6.1
46
- New option test_reqiure_paths for test task.
50
+ New option test_require_paths for test task.
47
51
 
48
52
  1.6.0
49
53
  New task: pry
data/Rakefile CHANGED
@@ -1,7 +1,6 @@
1
1
  $:.unshift File.dirname(__FILE__) + '/lib'
2
2
  require 'rim'
3
3
  require 'rim/aspell'
4
- require 'rim/check_version'
5
4
  require 'rim/gem'
6
5
  require 'rim/git'
7
6
  require 'rim/info'
@@ -9,6 +8,7 @@ require 'rim/rdoc'
9
8
  require 'rim/regtest'
10
9
  require 'rim/release'
11
10
  require 'rim/test'
11
+ require 'rim/version'
12
12
 
13
13
  Rim.setup do
14
14
  name 'rim'
data/lib/rim/aspell.rb CHANGED
@@ -1,30 +1,38 @@
1
1
  # -- encoding: utf-8 --
2
2
  class Rim
3
+ # Encoding odf spell checked files (default: 'UTF-8')
4
+ attr_accessor :aspell_encoding
5
+
3
6
  # Files to check via aspell (default: /^README/i, /^Changelog/i)
4
7
  attr_accessor :aspell_files
5
8
 
6
9
  # Language for aspell (default: 'en')
7
10
  attr_accessor :aspell_lang
11
+
12
+ # File to store the word list of the project (default: './.aspell.pws')
13
+ attr_accessor :aspell_word_list
8
14
  end
9
15
 
10
16
  Rim.defaults do
17
+ aspell_encoding 'UTF-8'
11
18
  aspell_files filelist(/^README/i, /^Changelog/i)
12
19
  aspell_lang 'en'
20
+ aspell_word_list './.aspell.pws'
13
21
  end
14
22
 
15
23
  Rim.after_setup do
16
- desc 'Check files via aspell'
24
+ desc 'Interactive spelling check via aspell'
17
25
  task :aspell do
18
26
  aspell_files.each do |fn|
19
- sh "aspell -c -x -l #{aspell_lang} #{fn}"
27
+ sh "aspell -c -x --encoding=#{aspell_encoding} -l #{aspell_lang} -p #{aspell_word_list} #{fn}"
20
28
  end
21
29
  end
22
30
  namespace :aspell do
23
- desc 'Test if there are no spellcheck errors'
31
+ desc 'Check if there are no spellcheck errors'
24
32
  task :check do
25
33
  error_files = []
26
34
  aspell_files.each do |fn|
27
- unless `aspell list -l #{aspell_lang} < #{fn}`.empty?
35
+ unless `aspell list --encoding=#{aspell_encoding} -l #{aspell_lang} -p #{aspell_word_list} < #{fn}`.empty?
28
36
  error_files << fn
29
37
  end
30
38
  end
@@ -0,0 +1,25 @@
1
+ # -- encoding: utf-8 --
2
+ Rim.after_setup do
3
+ namespace :version do
4
+ changelog = filelist(/^Changelog/i).first
5
+ desc "Check if version in #{changelog} is equal to Rim#version."
6
+ task :check do
7
+ line = File.open(changelog) do |f|
8
+ f.readline
9
+ end
10
+ if line =~ /^(\d+\.\d+(?:\.\d+)+)/
11
+ if $1 != version
12
+ fail "Version error (#{changelog}: #$1, Rim#version: #{version})"
13
+ end
14
+ else
15
+ fail "No version information in #{changelog}"
16
+ end
17
+ end
18
+ end
19
+ if feature_loaded? 'rim/gem'
20
+ task :gem => 'version:check'
21
+ end
22
+ if feature_loaded? 'rim/release'
23
+ task :release => 'version:check'
24
+ end
25
+ end
data/lib/rim.rb CHANGED
@@ -9,7 +9,7 @@ require 'singleton'
9
9
  # versions as possible and is easy to extend. Feel free to dislike it. ;)
10
10
  class Rim
11
11
 
12
- VERSION = '2.1.0'
12
+ VERSION = '2.2.0'
13
13
 
14
14
  begin
15
15
  require 'rake/dsl_definition'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rim
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan Friedrich
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-02-26 00:00:00.000000000 Z
11
+ date: 2014-02-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rim
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '2.1'
19
+ version: '2.2'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '2.1'
26
+ version: '2.2'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: regtest
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -52,7 +52,6 @@ files:
52
52
  - Rakefile
53
53
  - lib/rim.rb
54
54
  - lib/rim/aspell.rb
55
- - lib/rim/check_version.rb
56
55
  - lib/rim/core.rb
57
56
  - lib/rim/gem.rb
58
57
  - lib/rim/git.rb
@@ -66,6 +65,7 @@ files:
66
65
  - lib/rim/ripl.rb
67
66
  - lib/rim/test.rb
68
67
  - lib/rim/tire.rb
68
+ - lib/rim/version.rb
69
69
  - test/test_helper_methods.rb
70
70
  homepage: http://gitorious.org/rim
71
71
  licenses:
@@ -1,23 +0,0 @@
1
- # -- encoding: utf-8 --
2
- Rim.after_setup do
3
- changelog = filelist(/^Changelog/i).first
4
- desc "Check version in #{changelog} with Rim#version."
5
- task :check_version do
6
- line = File.open(changelog) do |f|
7
- f.readline
8
- end
9
- if line =~ /^(\d+\.\d+(?:\.\d+)+)/
10
- if $1 != version
11
- fail "Version error (#{changelog}: #$1, setup: #{version})"
12
- end
13
- else
14
- fail "No version information in #{changelog}"
15
- end
16
- end
17
- if feature_loaded? 'rim/gem'
18
- task :gem => :check_version
19
- end
20
- if feature_loaded? 'rim/release'
21
- task :release => :check_version
22
- end
23
- end