whitespace 2.0.0 → 2.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/bin/whitespace +3 -3
  2. metadata +5 -7
data/bin/whitespace CHANGED
@@ -9,7 +9,7 @@
9
9
  class WhitespaceProcessor
10
10
  def self.process(code)
11
11
  result = []
12
- code.each do |line|
12
+ code.each_line do |line|
13
13
  line.gsub!(/(\s+)$/, "\n")
14
14
  line.gsub!(/\t/, ' ')
15
15
  result << line
@@ -38,9 +38,9 @@ else
38
38
  end
39
39
 
40
40
  files.each do |line|
41
- line = line.split(/[\t\s]+/).last
41
+ line = line.split(":").last.strip
42
42
  puts " processing #{line}..."
43
43
  code = File.read(line)
44
44
  File.open(line, 'w+') { |f| f << (WhitespaceProcessor.process(code)) }
45
45
  end
46
- puts "* DONE"
46
+ puts "* DONE"
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: whitespace
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
4
+ hash: 13
5
5
  prerelease:
6
6
  segments:
7
7
  - 2
8
8
  - 0
9
- - 0
10
- version: 2.0.0
9
+ - 1
10
+ version: 2.0.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Pat Nakajima
@@ -15,8 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-01-19 00:00:00 -05:00
19
- default_executable: whitespace
18
+ date: 2011-01-19 00:00:00 Z
20
19
  dependencies: []
21
20
 
22
21
  description:
@@ -30,7 +29,6 @@ extra_rdoc_files: []
30
29
  files:
31
30
  - README
32
31
  - bin/whitespace
33
- has_rdoc: true
34
32
  homepage: https://github.com/nakajima/whitespace
35
33
  licenses: []
36
34
 
@@ -60,7 +58,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
60
58
  requirements: []
61
59
 
62
60
  rubyforge_project:
63
- rubygems_version: 1.4.1
61
+ rubygems_version: 1.8.2
64
62
  signing_key:
65
63
  specification_version: 3
66
64
  summary: Strips whitespace from files modified by git