csv_shaper 1.3.1 → 1.4.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a80ca33e1cff80cda6f06d8ee7d8b6c33229b2911031de5ee2d2d1a02e3f6c05
4
- data.tar.gz: 054dbdc041cbbc51063b6988fe1a0a2d9d085ec4f3e3bf5209f9c0038b523316
3
+ metadata.gz: e6edb9be614833680b5b60d6d7f5c6f5aeed56481f521bbc9bba18ad850d4f19
4
+ data.tar.gz: f1824877c0c6c4c733cfeb56026f06246178b1162ebb8604d7c11acf22908bbf
5
5
  SHA512:
6
- metadata.gz: 1720b33b849287cb2695395ea797beec679bf64776c03186020c86cbc26e4261224a66157642c62c9e440321dedae823976cb218d0823ed2e3faa2f9760d007e
7
- data.tar.gz: d0814a238d065a7ec894cebb1aff61b5aafdd70a3927d2b668a19f9f50b54c20238180666db32ae4f72f02413c6b54b4a9e0e8f734f22ff9b239b691e5cf8686
6
+ metadata.gz: b072f041568ddca49a3c757ca2ce4af9d29fa75ed43cc8ee0b141ad4d271e565941e3b159ead392b81ca6e1d7a2a24d65c311c05908180037f7f734a41259cbb
7
+ data.tar.gz: 2e1edd44e3574270fc83e4869082916d9e6ccb8081177cadc9994bef90fb4cf7212d2481bbe6e162efd5f3d18e0ca82fb9c80186e2611fa2e5b86cf32cc0dd42
@@ -0,0 +1,46 @@
1
+ name: Ruby Gem
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - "main"
7
+ paths:
8
+ - "lib/csv_shaper/version.rb"
9
+
10
+ jobs:
11
+ build:
12
+ name: Build + Publish
13
+ runs-on: ubuntu-latest
14
+ permissions:
15
+ contents: read
16
+ packages: write
17
+
18
+ steps:
19
+ - uses: actions/checkout@v4
20
+ - name: Set up Ruby 3.4
21
+ uses: ruby/setup-ruby@v1
22
+ with:
23
+ ruby-version: 3.4.2
24
+
25
+ - name: Publish to GPR
26
+ run: |
27
+ mkdir -p $HOME/.gem
28
+ touch $HOME/.gem/credentials
29
+ chmod 0600 $HOME/.gem/credentials
30
+ printf -- "---\n:github: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
31
+ gem build *.gemspec
32
+ gem push --KEY github --host https://rubygems.pkg.github.com/${OWNER} *.gem
33
+ env:
34
+ GEM_HOST_API_KEY: "Bearer ${{secrets.GITHUB_TOKEN}}"
35
+ OWNER: ${{ github.repository_owner }}
36
+
37
+ - name: Publish to RubyGems
38
+ run: |
39
+ mkdir -p $HOME/.gem
40
+ touch $HOME/.gem/credentials
41
+ chmod 0600 $HOME/.gem/credentials
42
+ printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
43
+ gem build *.gemspec
44
+ gem push *.gem
45
+ env:
46
+ GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_AUTH_TOKEN}}"
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.3.1
1
+ 3.4.1
data/README.md CHANGED
@@ -4,10 +4,7 @@ Beautiful DSL for creating CSV output in Ruby & Rails.
4
4
 
5
5
  Creating CSV files in Ruby is painful! CSV Shaper makes life easier! It's ideal for converting database backed models with attributes into CSV output. It can be used without Rails, but works great with ActiveRecord models and even comes with support for its own template handling.
6
6
 
7
- [![Build Status](https://secure.travis-ci.org/paulspringett/csv_shaper.png?branch=master)](http://travis-ci.org/paulspringett/csv_shaper)
8
- [![Code Climate](https://codeclimate.com/github/paulspringett/csv_shaper.png)](https://codeclimate.com/github/paulspringett/csv_shaper)
9
-
10
- Annotated source: http://paulspringett.github.com/csv_shaper/
7
+ Annotated source: http://paulspringett.github.io/csv_shaper/
11
8
 
12
9
  ### Example Usage
13
10
 
data/csv_shaper.gemspec CHANGED
@@ -1,4 +1,3 @@
1
- # -*- encoding: utf-8 -*-
2
1
  require File.expand_path('../lib/csv_shaper/version', __FILE__)
3
2
 
4
3
  Gem::Specification.new do |gem|
@@ -25,6 +24,7 @@ Gem::Specification.new do |gem|
25
24
  gem.version = CsvShaper::VERSION
26
25
 
27
26
  gem.add_dependency 'activesupport', '>= 3.0.0'
27
+ gem.add_dependency 'csv' if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.3')
28
28
  gem.add_development_dependency 'rspec'
29
29
  gem.add_development_dependency 'rake'
30
30
  end
@@ -33,7 +33,7 @@ module CsvShaper
33
33
 
34
34
  table = CSV::Table.new(rows)
35
35
  csv_options.except!(*custom_options.keys)
36
- table.to_csv(csv_options)
36
+ table.to_csv(**csv_options)
37
37
  end
38
38
 
39
39
  private
@@ -1,3 +1,4 @@
1
+ # 2
1
2
  module CsvShaper
2
- VERSION = "1.3.1"
3
+ VERSION = "1.4.0"
3
4
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: csv_shaper
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.1
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Springett
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2019-08-31 00:00:00.000000000 Z
10
+ date: 2025-03-19 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: activesupport
@@ -24,6 +23,20 @@ dependencies:
24
23
  - - ">="
25
24
  - !ruby/object:Gem::Version
26
25
  version: 3.0.0
26
+ - !ruby/object:Gem::Dependency
27
+ name: csv
28
+ requirement: !ruby/object:Gem::Requirement
29
+ requirements:
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
33
+ type: :runtime
34
+ prerelease: false
35
+ version_requirements: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
27
40
  - !ruby/object:Gem::Dependency
28
41
  name: rspec
29
42
  requirement: !ruby/object:Gem::Requirement
@@ -62,11 +75,11 @@ executables: []
62
75
  extensions: []
63
76
  extra_rdoc_files: []
64
77
  files:
78
+ - ".github/workflows/gem-push.yml"
65
79
  - ".gitignore"
66
80
  - ".groc.json"
67
81
  - ".rspec"
68
82
  - ".ruby-version"
69
- - ".travis.yml"
70
83
  - Gemfile
71
84
  - LICENSE
72
85
  - README.md
@@ -93,7 +106,6 @@ homepage: http://github.com/paulspringett/csv_shaper
93
106
  licenses:
94
107
  - MIT
95
108
  metadata: {}
96
- post_install_message:
97
109
  rdoc_options: []
98
110
  require_paths:
99
111
  - lib
@@ -108,17 +120,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
108
120
  - !ruby/object:Gem::Version
109
121
  version: '0'
110
122
  requirements: []
111
- rubyforge_project:
112
- rubygems_version: 2.7.7
113
- signing_key:
123
+ rubygems_version: 3.6.2
114
124
  specification_version: 4
115
125
  summary: Beautiful DSL for creating CSV output in Ruby & Rails
116
- test_files:
117
- - spec/config_spec.rb
118
- - spec/csv_shaper_spec.rb
119
- - spec/csv_shaper_template_spec.rb
120
- - spec/encoder_spec.rb
121
- - spec/fixtures/user.rb
122
- - spec/header_spec.rb
123
- - spec/row_spec.rb
124
- - spec/spec_helper.rb
126
+ test_files: []
data/.travis.yml DELETED
@@ -1,3 +0,0 @@
1
- rvm:
2
- - 2.2.5
3
- - 2.3.1