windows_csv 0.0.8 → 0.0.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Rakefile +13 -25
- data/lib/windows_csv.rb +42 -42
- metadata +62 -55
- data/.document +0 -5
- data/.rspec +0 -1
- data/Gemfile +0 -13
- data/Gemfile.lock +0 -31
- data/VERSION +0 -1
- data/spec/spec_helper.rb +0 -12
- data/spec/windows_csv_spec.rb +0 -35
- data/windows_csv.gemspec +0 -60
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 42e240c1188e10fcbdc2e092ba0a3174abe85e8dfb58cd83edb73ffc4313e70d
|
4
|
+
data.tar.gz: ba1756793a0286cebfb43050d48fa6e621a8dcf1a5796a2f6a756e729869dae5
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: a988733b0fd2a6fe9facaaf26072bd3c7e2fe05fe1197a72ac316d79d1206fb30c0aabf254853037d3003d618986160a4a374139207b7828158285fc71f5530c
|
7
|
+
data.tar.gz: 0f7cf5c38263f31db5b1a03e899ea1b27eadf11799cf1a6ed9cff1b77055cfc176fdf1c0b75aabf96d4331be588eee959cce6def622fcd9821fb2b1d859bbc6b
|
data/Rakefile
CHANGED
@@ -1,49 +1,37 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
require 'rubygems'
|
4
|
-
require 'bundler'
|
1
|
+
require "rubygems"
|
2
|
+
require "bundler"
|
5
3
|
begin
|
6
4
|
Bundler.setup(:default, :development)
|
7
5
|
rescue Bundler::BundlerError => e
|
8
|
-
|
9
|
-
|
6
|
+
warn e.message
|
7
|
+
warn "Run `bundle install` to install missing gems"
|
10
8
|
exit e.status_code
|
11
9
|
end
|
12
|
-
require
|
10
|
+
require "rake"
|
13
11
|
|
14
|
-
require
|
12
|
+
require "jeweler"
|
15
13
|
Jeweler::Tasks.new do |gem|
|
16
14
|
# gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
|
17
15
|
gem.name = "windows_csv"
|
18
16
|
gem.homepage = "http://github.com/kaspernj/windows_csv"
|
19
17
|
gem.license = "MIT"
|
20
|
-
gem.summary = %
|
21
|
-
gem.description = %
|
18
|
+
gem.summary = %(A framework to write Windows CSV files.)
|
19
|
+
gem.description = %(A framework to write Windows CSV files.)
|
22
20
|
gem.email = "k@spernj.org"
|
23
21
|
gem.authors = ["kaspernj"]
|
24
22
|
# dependencies defined in Gemfile
|
25
23
|
end
|
26
24
|
Jeweler::RubygemsDotOrgTasks.new
|
27
25
|
|
28
|
-
require
|
29
|
-
require
|
26
|
+
require "rspec/core"
|
27
|
+
require "rspec/core/rake_task"
|
30
28
|
RSpec::Core::RakeTask.new(:spec) do |spec|
|
31
|
-
spec.pattern = FileList[
|
29
|
+
spec.pattern = FileList["spec/**/*_spec.rb"]
|
32
30
|
end
|
33
31
|
|
34
32
|
RSpec::Core::RakeTask.new(:rcov) do |spec|
|
35
|
-
spec.pattern =
|
33
|
+
spec.pattern = "spec/**/*_spec.rb"
|
36
34
|
spec.rcov = true
|
37
35
|
end
|
38
36
|
|
39
|
-
task :
|
40
|
-
|
41
|
-
require 'rdoc/task'
|
42
|
-
Rake::RDocTask.new do |rdoc|
|
43
|
-
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
44
|
-
|
45
|
-
rdoc.rdoc_dir = 'rdoc'
|
46
|
-
rdoc.title = "windows_csv #{version}"
|
47
|
-
rdoc.rdoc_files.include('README*')
|
48
|
-
rdoc.rdoc_files.include('lib/**/*.rb')
|
49
|
-
end
|
37
|
+
task default: :spec
|
data/lib/windows_csv.rb
CHANGED
@@ -1,37 +1,37 @@
|
|
1
|
-
#This class was heavily inspired by the great Dipth! https://github.com/dipth
|
1
|
+
# This class was heavily inspired by the great Dipth! https://github.com/dipth
|
2
2
|
class WindowsCsv
|
3
3
|
BOM = "\377\376".force_encoding(Encoding::UTF_16LE) # Byte Order Mark
|
4
|
-
COL_SEP = ";"
|
5
|
-
QUOTE_CHAR = "\""
|
6
|
-
ROW_SEP = "\r\n"
|
7
|
-
|
8
|
-
ARGS = {
|
9
|
-
:
|
10
|
-
:
|
11
|
-
:
|
4
|
+
COL_SEP = ";".freeze
|
5
|
+
QUOTE_CHAR = "\"".freeze
|
6
|
+
ROW_SEP = "\r\n".freeze
|
7
|
+
|
8
|
+
ARGS = { # rubocop:disable Style/MutableConstant
|
9
|
+
col_sep: COL_SEP,
|
10
|
+
quote_char: QUOTE_CHAR,
|
11
|
+
row_sep: ROW_SEP
|
12
12
|
}
|
13
|
-
|
13
|
+
|
14
14
|
REPLACES = {
|
15
15
|
"\r\n" => "\\r\\n",
|
16
16
|
"\r" => "\\r",
|
17
17
|
"\n" => "\\n"
|
18
|
-
}
|
19
|
-
|
20
|
-
#Loops through a Windows CSV file with leading BOM, tabs as col-sep, quote char " and row sep \r\n
|
21
|
-
def self.foreach(path, args = {})
|
18
|
+
}.freeze
|
19
|
+
|
20
|
+
# Loops through a Windows CSV file with leading BOM, tabs as col-sep, quote char " and row sep \r\n
|
21
|
+
def self.foreach(path, args = {}) # rubocop:disable Metrics/AbcSize
|
22
22
|
require "csv"
|
23
|
-
|
23
|
+
|
24
24
|
File.open(path, "rb:bom|utf-16le") do |fp|
|
25
25
|
csv_args = ARGS.clone
|
26
26
|
csv_args.merge!(args[:csv_args]) if args[:csv_args]
|
27
|
-
|
28
|
-
CSV.foreach(fp, csv_args) do |row|
|
27
|
+
|
28
|
+
CSV.foreach(fp, **csv_args) do |row|
|
29
29
|
if csv_args[:headers]
|
30
30
|
real = {}
|
31
31
|
else
|
32
32
|
real = []
|
33
33
|
end
|
34
|
-
|
34
|
+
|
35
35
|
row.each do |col|
|
36
36
|
if csv_args[:headers]
|
37
37
|
real[col[0].to_sym] = WindowsCsv.unescape(col[1])
|
@@ -39,37 +39,37 @@ class WindowsCsv
|
|
39
39
|
real << WindowsCsv.unescape(col)
|
40
40
|
end
|
41
41
|
end
|
42
|
-
|
42
|
+
|
43
43
|
yield real
|
44
44
|
end
|
45
45
|
end
|
46
|
-
|
46
|
+
|
47
47
|
nil
|
48
48
|
end
|
49
|
-
|
49
|
+
|
50
50
|
def initialize(args)
|
51
51
|
require "csv"
|
52
|
-
|
52
|
+
|
53
53
|
@args = args
|
54
|
-
|
54
|
+
|
55
55
|
if @args[:path]
|
56
|
-
fp = File.open(@args[:path], "w", :
|
56
|
+
fp = File.open(@args[:path], "w", encoding: Encoding::UTF_8)
|
57
57
|
@args[:io] = fp
|
58
58
|
end
|
59
|
-
|
59
|
+
|
60
60
|
begin
|
61
61
|
@args[:io].write(BOM)
|
62
62
|
yield self
|
63
63
|
ensure
|
64
|
-
fp
|
64
|
+
fp&.close
|
65
65
|
end
|
66
66
|
end
|
67
|
-
|
67
|
+
|
68
68
|
def <<(row)
|
69
69
|
encoded = []
|
70
|
-
|
70
|
+
|
71
71
|
row.each do |col|
|
72
|
-
if col.is_a?(Time)
|
72
|
+
if col.is_a?(Time) || col.is_a?(DateTime)
|
73
73
|
encoded << col.strftime("%Y-%m-%d %H:%M")
|
74
74
|
elsif col.is_a?(Date)
|
75
75
|
encoded << col.strftime("%Y-%m-%d")
|
@@ -77,29 +77,29 @@ class WindowsCsv
|
|
77
77
|
encoded << WindowsCsv.escape(col)
|
78
78
|
end
|
79
79
|
end
|
80
|
-
|
81
|
-
@args[:io].write CSV.generate_line(encoded, ARGS).encode(Encoding::UTF_16LE)
|
82
|
-
|
83
|
-
|
80
|
+
|
81
|
+
@args[:io].write CSV.generate_line(encoded, **ARGS).encode(Encoding::UTF_16LE)
|
82
|
+
|
83
|
+
nil
|
84
84
|
end
|
85
|
-
|
85
|
+
|
86
86
|
def self.escape(str)
|
87
87
|
str = str.to_s
|
88
|
-
|
88
|
+
|
89
89
|
REPLACES.each do |key, val|
|
90
90
|
str = str.gsub(key, val)
|
91
91
|
end
|
92
|
-
|
93
|
-
|
92
|
+
|
93
|
+
str
|
94
94
|
end
|
95
|
-
|
95
|
+
|
96
96
|
def self.unescape(str)
|
97
97
|
str = str.to_s
|
98
|
-
|
98
|
+
|
99
99
|
REPLACES.each do |key, val|
|
100
100
|
str = str.gsub(val, key)
|
101
101
|
end
|
102
|
-
|
103
|
-
|
102
|
+
|
103
|
+
str
|
104
104
|
end
|
105
|
-
end
|
105
|
+
end
|
metadata
CHANGED
@@ -1,80 +1,99 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: windows_csv
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
version: 0.0.8
|
4
|
+
version: 0.0.9
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- kaspernj
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2022-12-06 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 1.0.0
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
15
22
|
version_requirements: !ruby/object:Gem::Requirement
|
16
|
-
none: false
|
17
23
|
requirements:
|
18
|
-
- -
|
24
|
+
- - ">="
|
19
25
|
- !ruby/object:Gem::Version
|
20
|
-
version:
|
26
|
+
version: 1.0.0
|
27
|
+
- !ruby/object:Gem::Dependency
|
21
28
|
name: rspec
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 3.12.0
|
22
34
|
type: :development
|
23
35
|
prerelease: false
|
24
|
-
|
25
|
-
none: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
37
|
requirements:
|
27
|
-
- - ~>
|
38
|
+
- - "~>"
|
28
39
|
- !ruby/object:Gem::Version
|
29
|
-
version:
|
40
|
+
version: 3.12.0
|
30
41
|
- !ruby/object:Gem::Dependency
|
31
|
-
|
32
|
-
|
42
|
+
name: rubocop
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
33
44
|
requirements:
|
34
|
-
- -
|
45
|
+
- - ">="
|
35
46
|
- !ruby/object:Gem::Version
|
36
|
-
version: '
|
37
|
-
name: rdoc
|
47
|
+
version: '0'
|
38
48
|
type: :development
|
39
49
|
prerelease: false
|
40
|
-
|
41
|
-
none: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
42
51
|
requirements:
|
43
|
-
- -
|
52
|
+
- - ">="
|
44
53
|
- !ruby/object:Gem::Version
|
45
|
-
version: '
|
54
|
+
version: '0'
|
46
55
|
- !ruby/object:Gem::Dependency
|
47
|
-
|
48
|
-
|
56
|
+
name: rubocop-performance
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
49
58
|
requirements:
|
50
|
-
- -
|
59
|
+
- - ">="
|
51
60
|
- !ruby/object:Gem::Version
|
52
|
-
version:
|
53
|
-
name: bundler
|
61
|
+
version: '0'
|
54
62
|
type: :development
|
55
63
|
prerelease: false
|
56
|
-
|
57
|
-
none: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
58
65
|
requirements:
|
59
|
-
- -
|
66
|
+
- - ">="
|
60
67
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
68
|
+
version: '0'
|
62
69
|
- !ruby/object:Gem::Dependency
|
63
|
-
|
64
|
-
|
70
|
+
name: rubocop-rake
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
65
72
|
requirements:
|
66
|
-
- -
|
73
|
+
- - ">="
|
67
74
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
69
|
-
name: jeweler
|
75
|
+
version: '0'
|
70
76
|
type: :development
|
71
77
|
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: rubocop-rspec
|
72
85
|
requirement: !ruby/object:Gem::Requirement
|
73
|
-
none: false
|
74
86
|
requirements:
|
75
|
-
- -
|
87
|
+
- - ">="
|
76
88
|
- !ruby/object:Gem::Version
|
77
|
-
version:
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
78
97
|
description: A framework to write Windows CSV files.
|
79
98
|
email: k@spernj.org
|
80
99
|
executables: []
|
@@ -83,44 +102,32 @@ extra_rdoc_files:
|
|
83
102
|
- LICENSE.txt
|
84
103
|
- README.rdoc
|
85
104
|
files:
|
86
|
-
- .document
|
87
|
-
- .rspec
|
88
|
-
- Gemfile
|
89
|
-
- Gemfile.lock
|
90
105
|
- LICENSE.txt
|
91
106
|
- README.rdoc
|
92
107
|
- Rakefile
|
93
|
-
- VERSION
|
94
108
|
- lib/windows_csv.rb
|
95
|
-
- spec/spec_helper.rb
|
96
|
-
- spec/windows_csv_spec.rb
|
97
|
-
- windows_csv.gemspec
|
98
109
|
homepage: http://github.com/kaspernj/windows_csv
|
99
110
|
licenses:
|
100
111
|
- MIT
|
112
|
+
metadata:
|
113
|
+
rubygems_mfa_required: 'true'
|
101
114
|
post_install_message:
|
102
115
|
rdoc_options: []
|
103
116
|
require_paths:
|
104
117
|
- lib
|
105
118
|
required_ruby_version: !ruby/object:Gem::Requirement
|
106
|
-
none: false
|
107
119
|
requirements:
|
108
|
-
- -
|
120
|
+
- - ">="
|
109
121
|
- !ruby/object:Gem::Version
|
110
|
-
|
111
|
-
- 0
|
112
|
-
hash: 3869959267862217963
|
113
|
-
version: '0'
|
122
|
+
version: 2.6.8
|
114
123
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
115
|
-
none: false
|
116
124
|
requirements:
|
117
|
-
- -
|
125
|
+
- - ">="
|
118
126
|
- !ruby/object:Gem::Version
|
119
127
|
version: '0'
|
120
128
|
requirements: []
|
121
|
-
|
122
|
-
rubygems_version: 1.8.23
|
129
|
+
rubygems_version: 3.3.7
|
123
130
|
signing_key:
|
124
|
-
specification_version:
|
131
|
+
specification_version: 4
|
125
132
|
summary: A framework to write Windows CSV files.
|
126
133
|
test_files: []
|
data/.document
DELETED
data/.rspec
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
--color
|
data/Gemfile
DELETED
@@ -1,13 +0,0 @@
|
|
1
|
-
source "http://rubygems.org"
|
2
|
-
# Add dependencies required to use your gem here.
|
3
|
-
# Example:
|
4
|
-
# gem "activesupport", ">= 2.3.5"
|
5
|
-
|
6
|
-
# Add dependencies to develop your gem here.
|
7
|
-
# Include everything needed to run rake, tests, features, etc.
|
8
|
-
group :development do
|
9
|
-
gem "rspec", "~> 2.8.0"
|
10
|
-
gem "rdoc", "~> 3.12"
|
11
|
-
gem "bundler", ">= 1.0.0"
|
12
|
-
gem "jeweler", "~> 1.8.4"
|
13
|
-
end
|
data/Gemfile.lock
DELETED
@@ -1,31 +0,0 @@
|
|
1
|
-
GEM
|
2
|
-
remote: http://rubygems.org/
|
3
|
-
specs:
|
4
|
-
diff-lcs (1.1.3)
|
5
|
-
git (1.2.5)
|
6
|
-
jeweler (1.8.4)
|
7
|
-
bundler (~> 1.0)
|
8
|
-
git (>= 1.2.5)
|
9
|
-
rake
|
10
|
-
rdoc
|
11
|
-
json (1.7.7)
|
12
|
-
rake (10.0.4)
|
13
|
-
rdoc (3.12.2)
|
14
|
-
json (~> 1.4)
|
15
|
-
rspec (2.8.0)
|
16
|
-
rspec-core (~> 2.8.0)
|
17
|
-
rspec-expectations (~> 2.8.0)
|
18
|
-
rspec-mocks (~> 2.8.0)
|
19
|
-
rspec-core (2.8.0)
|
20
|
-
rspec-expectations (2.8.0)
|
21
|
-
diff-lcs (~> 1.1.2)
|
22
|
-
rspec-mocks (2.8.0)
|
23
|
-
|
24
|
-
PLATFORMS
|
25
|
-
ruby
|
26
|
-
|
27
|
-
DEPENDENCIES
|
28
|
-
bundler (>= 1.0.0)
|
29
|
-
jeweler (~> 1.8.4)
|
30
|
-
rdoc (~> 3.12)
|
31
|
-
rspec (~> 2.8.0)
|
data/VERSION
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
0.0.8
|
data/spec/spec_helper.rb
DELETED
@@ -1,12 +0,0 @@
|
|
1
|
-
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
2
|
-
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
3
|
-
require 'rspec'
|
4
|
-
require 'windows_csv'
|
5
|
-
|
6
|
-
# Requires supporting files with custom matchers and macros, etc,
|
7
|
-
# in ./support/ and its subdirectories.
|
8
|
-
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
|
9
|
-
|
10
|
-
RSpec.configure do |config|
|
11
|
-
|
12
|
-
end
|
data/spec/windows_csv_spec.rb
DELETED
@@ -1,35 +0,0 @@
|
|
1
|
-
#encoding: utf-8
|
2
|
-
|
3
|
-
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
4
|
-
|
5
|
-
describe "WindowsCsv" do
|
6
|
-
it "works" do
|
7
|
-
require "tmpdir"
|
8
|
-
require "digest"
|
9
|
-
require "digest/md5"
|
10
|
-
|
11
|
-
tmpfile = "#{Dir.tmpdir}/windows_csv_test_#{Digest::MD5.hexdigest(Time.now.to_f.to_s)}.csv"
|
12
|
-
|
13
|
-
WindowsCsv.new(:path => tmpfile) do |csv|
|
14
|
-
csv << ["Name1", "Name2", "Encoding", "Date", "Time", "DateTime", "MultiLine"]
|
15
|
-
csv << ["Kasper", "Christina", "æøå", Date.new, Time.new, DateTime.new, "Multi\nLine"]
|
16
|
-
csv << ["Thomas", "Nikolaj", "læp", nil, nil, nil, nil]
|
17
|
-
end
|
18
|
-
|
19
|
-
puts "Path: #{tmpfile}"
|
20
|
-
|
21
|
-
count = 0
|
22
|
-
WindowsCsv.foreach(tmpfile, :csv_args => {:headers => true}) do |row|
|
23
|
-
count += 1
|
24
|
-
#puts "Row: #{row}"
|
25
|
-
|
26
|
-
if count == 1
|
27
|
-
row[:Name2].should eql("Christina")
|
28
|
-
row[:Encoding].should eql("æøå")
|
29
|
-
row[:MultiLine].should eql("Multi\nLine")
|
30
|
-
end
|
31
|
-
end
|
32
|
-
|
33
|
-
count.should eql(2)
|
34
|
-
end
|
35
|
-
end
|
data/windows_csv.gemspec
DELETED
@@ -1,60 +0,0 @@
|
|
1
|
-
# Generated by jeweler
|
2
|
-
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
|
-
# -*- encoding: utf-8 -*-
|
5
|
-
|
6
|
-
Gem::Specification.new do |s|
|
7
|
-
s.name = "windows_csv"
|
8
|
-
s.version = "0.0.8"
|
9
|
-
|
10
|
-
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
-
s.authors = ["kaspernj"]
|
12
|
-
s.date = "2013-05-03"
|
13
|
-
s.description = "A framework to write Windows CSV files."
|
14
|
-
s.email = "k@spernj.org"
|
15
|
-
s.extra_rdoc_files = [
|
16
|
-
"LICENSE.txt",
|
17
|
-
"README.rdoc"
|
18
|
-
]
|
19
|
-
s.files = [
|
20
|
-
".document",
|
21
|
-
".rspec",
|
22
|
-
"Gemfile",
|
23
|
-
"Gemfile.lock",
|
24
|
-
"LICENSE.txt",
|
25
|
-
"README.rdoc",
|
26
|
-
"Rakefile",
|
27
|
-
"VERSION",
|
28
|
-
"lib/windows_csv.rb",
|
29
|
-
"spec/spec_helper.rb",
|
30
|
-
"spec/windows_csv_spec.rb",
|
31
|
-
"windows_csv.gemspec"
|
32
|
-
]
|
33
|
-
s.homepage = "http://github.com/kaspernj/windows_csv"
|
34
|
-
s.licenses = ["MIT"]
|
35
|
-
s.require_paths = ["lib"]
|
36
|
-
s.rubygems_version = "1.8.23"
|
37
|
-
s.summary = "A framework to write Windows CSV files."
|
38
|
-
|
39
|
-
if s.respond_to? :specification_version then
|
40
|
-
s.specification_version = 3
|
41
|
-
|
42
|
-
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
43
|
-
s.add_development_dependency(%q<rspec>, ["~> 2.8.0"])
|
44
|
-
s.add_development_dependency(%q<rdoc>, ["~> 3.12"])
|
45
|
-
s.add_development_dependency(%q<bundler>, [">= 1.0.0"])
|
46
|
-
s.add_development_dependency(%q<jeweler>, ["~> 1.8.4"])
|
47
|
-
else
|
48
|
-
s.add_dependency(%q<rspec>, ["~> 2.8.0"])
|
49
|
-
s.add_dependency(%q<rdoc>, ["~> 3.12"])
|
50
|
-
s.add_dependency(%q<bundler>, [">= 1.0.0"])
|
51
|
-
s.add_dependency(%q<jeweler>, ["~> 1.8.4"])
|
52
|
-
end
|
53
|
-
else
|
54
|
-
s.add_dependency(%q<rspec>, ["~> 2.8.0"])
|
55
|
-
s.add_dependency(%q<rdoc>, ["~> 3.12"])
|
56
|
-
s.add_dependency(%q<bundler>, [">= 1.0.0"])
|
57
|
-
s.add_dependency(%q<jeweler>, ["~> 1.8.4"])
|
58
|
-
end
|
59
|
-
end
|
60
|
-
|