openxml-xlsx 0.2.0 → 0.2.5

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
- SHA1:
3
- metadata.gz: f094c3f3d320d437160ecde6d7bfa6658e4cbfb0
4
- data.tar.gz: abff7db10f7d3eae869fe36070badb0f3ddb12a1
2
+ SHA256:
3
+ metadata.gz: 9209c8d440ff1dc6a798dbca55faa3ea86e30488b8b626f43eb06184ea59de8c
4
+ data.tar.gz: e1867e7efc718fd9b192b1a00df26f7b49d17580a2b807661a4890d3220da079
5
5
  SHA512:
6
- metadata.gz: e125f39a4a02221a9610b96dcedc3544ca9aa8285d3b7d04abe5b2196e3c89477d24c5d09ce77eceb210495dc277c9c206a5a601ad888368b2e943cc0a3ce97a
7
- data.tar.gz: c1d013edf0c517011f5d4f0b1948ec017a966e92528c3d67e2c7deb544c0717b1dd174fd718428b7cc0e9e70ac7e60cce57d25b103d018607fa1e1bba50fa5a7
6
+ metadata.gz: 470a245da3608ddfdf4aa60d142fb71a358c7376853275969fcbd69e3c20f6a74ae5f8b5907ebe340c569e8b5f429961d2eef2f8eabee5d5e2232d90e4208725
7
+ data.tar.gz: ce7b45a14e845ea25fc352619c60c27b5f9c8b853e8683af063c570369fee9c8c73d6e784b02798a7e559aae75434690f8b2b0e24bfe2a69c659239eba37a1da
@@ -0,0 +1,17 @@
1
+ name: Tests
2
+ on: [push]
3
+
4
+ jobs:
5
+ ruby:
6
+ name: Tests
7
+ runs-on: ubuntu-latest
8
+ steps:
9
+ - name: Checkout
10
+ uses: actions/checkout@v2
11
+ - name: Setup Ruby
12
+ uses: ruby/setup-ruby@v1
13
+ with:
14
+ ruby-version: 2.6
15
+ bundler-cache: true
16
+ - name: Run the Tests
17
+ run: bundle exec rake spec
data/Gemfile.lock CHANGED
@@ -1,46 +1,55 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- openxml-xlsx (0.2.0)
4
+ openxml-xlsx (0.2.5)
5
5
  nokogiri
6
6
  openxml-package (>= 0.2.0)
7
7
 
8
8
  GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
- coderay (1.0.9)
12
- diff-lcs (1.2.5)
13
- method_source (0.8.1)
14
- mini_portile (0.6.2)
15
- multi_json (1.7.2)
16
- nokogiri (1.6.6.3)
17
- mini_portile (~> 0.6.0)
18
- openxml-package (0.2.0)
11
+ coderay (1.1.0)
12
+ diff-lcs (1.4.4)
13
+ docile (1.1.5)
14
+ json (1.8.6)
15
+ method_source (0.8.2)
16
+ mini_portile2 (2.6.1)
17
+ nokogiri (1.12.5)
18
+ mini_portile2 (~> 2.6.1)
19
+ racc (~> 1.4)
20
+ openxml-package (0.3.4)
19
21
  nokogiri
20
22
  ox
21
- rubyzip (~> 1.1.0)
22
- ox (2.2.2)
23
- pry (0.9.12)
24
- coderay (~> 1.0.5)
25
- method_source (~> 0.8)
23
+ rubyzip
24
+ ox (2.14.5)
25
+ pry (0.10.3)
26
+ coderay (~> 1.1.0)
27
+ method_source (~> 0.8.1)
26
28
  slop (~> 3.4)
27
- rake (10.0.4)
29
+ racc (1.6.0)
30
+ rake (12.3.3)
28
31
  rr (1.1.2)
29
- rspec (2.14.1)
30
- rspec-core (~> 2.14.0)
31
- rspec-expectations (~> 2.14.0)
32
- rspec-mocks (~> 2.14.0)
33
- rspec-core (2.14.7)
34
- rspec-expectations (2.14.4)
35
- diff-lcs (>= 1.1.3, < 2.0)
36
- rspec-mocks (2.14.4)
37
- rubyzip (1.1.7)
38
- simplecov (0.7.1)
39
- multi_json (~> 1.0)
40
- simplecov-html (~> 0.7.1)
41
- simplecov-html (0.7.1)
42
- slop (3.4.4)
43
- timecop (0.6.3)
32
+ rspec (3.10.0)
33
+ rspec-core (~> 3.10.0)
34
+ rspec-expectations (~> 3.10.0)
35
+ rspec-mocks (~> 3.10.0)
36
+ rspec-core (3.10.1)
37
+ rspec-support (~> 3.10.0)
38
+ rspec-expectations (3.10.1)
39
+ diff-lcs (>= 1.2.0, < 2.0)
40
+ rspec-support (~> 3.10.0)
41
+ rspec-mocks (3.10.2)
42
+ diff-lcs (>= 1.2.0, < 2.0)
43
+ rspec-support (~> 3.10.0)
44
+ rspec-support (3.10.2)
45
+ rubyzip (2.3.2)
46
+ simplecov (0.11.0)
47
+ docile (~> 1.1.0)
48
+ json (~> 1.8)
49
+ simplecov-html (~> 0.10.0)
50
+ simplecov-html (0.10.0)
51
+ slop (3.6.0)
52
+ timecop (0.8.0)
44
53
 
45
54
  PLATFORMS
46
55
  ruby
@@ -55,4 +64,4 @@ DEPENDENCIES
55
64
  timecop
56
65
 
57
66
  BUNDLED WITH
58
- 1.10.6
67
+ 2.2.17
data/README.md ADDED
@@ -0,0 +1,46 @@
1
+ # OpenXml::Xlsx
2
+
3
+ [![Gem Version](https://badge.fury.io/rb/openxml-xlsx.svg)](https://rubygems.org/gems/openxml-xlsx)
4
+ [![Code Climate](https://codeclimate.com/github/openxml/openxml-xlsx.svg)](https://codeclimate.com/github/openxml/openxml-xlsx)
5
+ [![Build Status](https://travis-ci.org/openxml/openxml-xlsx.svg)](https://travis-ci.org/openxml/openxml-xlsx)
6
+
7
+
8
+ ## Installation
9
+
10
+ Add this line to your application's Gemfile:
11
+
12
+ ```ruby
13
+ gem 'openxml-xlsx'
14
+ ```
15
+
16
+ And then execute:
17
+
18
+ $ bundle
19
+
20
+ Or install it yourself as:
21
+
22
+ $ gem install openxml-xlsx
23
+
24
+
25
+ ## Usage
26
+
27
+ TODO: Write usage instructions here
28
+
29
+
30
+ ## Development
31
+
32
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
33
+
34
+ Reference for SpreadsheetML can be found in Part 1 of the Fourth Edition of [ECMA-376](http://www.ecma-international.org/publications/standards/Ecma-376.htm) (the Office Open XML Standard).
35
+
36
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
37
+
38
+
39
+ ## Contributing
40
+
41
+ Bug reports and pull requests are welcome on GitHub at https://github.com/openxml/openxml-xlsx.
42
+
43
+
44
+ ## License
45
+
46
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
data/bin/console CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
3
  require "bundler/setup"
4
- require "xlsx"
4
+ require "openxml/xlsx"
5
5
 
6
6
  # You can add fixtures and/or initialization code here to make experimenting
7
7
  # with your gem easier. You can also use a different console, if you like.
data/example CHANGED
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- require "rails" # workaround: openxml-package uses `extract_options!`
4
3
  $:.push Dir.pwd + "/lib"
5
4
  require "openxml/xlsx"
5
+
6
6
  package = OpenXml::Xlsx::Package.new
7
7
  workbook = package.workbook
8
8
  worksheet = workbook.worksheets[0]
@@ -11,17 +11,18 @@ module OpenXml
11
11
  @column = options.fetch(:column)
12
12
  @value = options[:value]
13
13
  case value
14
- when String
15
- @type = :string
16
- @string_id = package.string_ref(value)
17
- when Date then
14
+ when Numeric
15
+ @type = :general
16
+ when Date
18
17
  @type = :date
19
18
  @serial_date = to_serial_date(value)
20
- when Time then
19
+ when Time
21
20
  @type = :time
22
21
  @serial_time = to_serial_time(value)
23
22
  else
24
- @type = :general
23
+ @value = value.to_s
24
+ @type = :string
25
+ @string_id = package.string_ref(value)
25
26
  end
26
27
  @style = package.style_ref(options[:style]) if options.key? :style
27
28
  @formula = options[:formula]
@@ -1,5 +1,5 @@
1
1
  module OpenXml
2
2
  module Xlsx
3
- VERSION = "0.2.0"
3
+ VERSION = "0.2.5"
4
4
  end
5
5
  end
data/openxml-xlsx.gemspec CHANGED
@@ -10,16 +10,17 @@ Gem::Specification.new do |spec|
10
10
  spec.email = ["bob.lailfamily@gmail.com"]
11
11
 
12
12
  spec.description = %q{Create Microsoft Excel (.xlsx) files.}
13
- spec.summary = %q{Using a simple API, create xlsx files programmatically}
14
- spec.license = "MIT"
13
+ spec.summary = %q{Implements the Office Open XML spec for creating SpreadsheetML documents}
15
14
  spec.homepage = "https://github.com/openxml/openxml-xlsx"
15
+ spec.license = "MIT"
16
16
 
17
17
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
18
18
  spec.bindir = "exe"
19
19
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
20
20
  spec.require_paths = ["lib"]
21
21
 
22
- spec.required_ruby_version = "~> 2.0"
22
+ spec.required_ruby_version = ">= 2.0"
23
+
23
24
  spec.add_dependency "nokogiri"
24
25
  spec.add_dependency "openxml-package", ">= 0.2.0"
25
26
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: openxml-xlsx
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bob Lail
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-11-20 00:00:00.000000000 Z
11
+ date: 2021-10-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri
@@ -129,10 +129,12 @@ executables: []
129
129
  extensions: []
130
130
  extra_rdoc_files: []
131
131
  files:
132
+ - ".github/workflows/ci.yml"
132
133
  - ".gitignore"
133
134
  - Gemfile
134
135
  - Gemfile.lock
135
136
  - LICENSE.txt
137
+ - README.md
136
138
  - Rakefile
137
139
  - bin/console
138
140
  - bin/setup
@@ -169,13 +171,13 @@ homepage: https://github.com/openxml/openxml-xlsx
169
171
  licenses:
170
172
  - MIT
171
173
  metadata: {}
172
- post_install_message:
174
+ post_install_message:
173
175
  rdoc_options: []
174
176
  require_paths:
175
177
  - lib
176
178
  required_ruby_version: !ruby/object:Gem::Requirement
177
179
  requirements:
178
- - - "~>"
180
+ - - ">="
179
181
  - !ruby/object:Gem::Version
180
182
  version: '2.0'
181
183
  required_rubygems_version: !ruby/object:Gem::Requirement
@@ -184,9 +186,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
184
186
  - !ruby/object:Gem::Version
185
187
  version: '0'
186
188
  requirements: []
187
- rubyforge_project:
188
- rubygems_version: 2.4.8
189
- signing_key:
189
+ rubygems_version: 3.2.15
190
+ signing_key:
190
191
  specification_version: 4
191
- summary: Using a simple API, create xlsx files programmatically
192
+ summary: Implements the Office Open XML spec for creating SpreadsheetML documents
192
193
  test_files: []