dbf 4.2.2 → 4.2.4

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
  SHA256:
3
- metadata.gz: 429e8806f5675886a27b904b879c244f9808c83c3da82937d6953d13a01dd333
4
- data.tar.gz: e3d916d24891b6f26237c41fc6cad865544b2c1b6c91430f93fad58a8d712298
3
+ metadata.gz: 458e14a93544a7b6ade6746332bcf39731780bd9af34aebee260e6abcca9543c
4
+ data.tar.gz: b0d645e6728a885db8d7a98c45f7be8aa9383561bae0b088f9b5b2dc6f1e6284
5
5
  SHA512:
6
- metadata.gz: 542522a8b7964b4a517bb4a1c68ae95ebbebab15ca4ef9ca8b6ce515b5a4df73e8c8b6dd27bf7c9273d6c879839c165ed94bfc17a2a26b069697b6badcbac3f9
7
- data.tar.gz: 81b8db3ad10edbef672257239b2c9389f7292420feb7fab8343c9e2736bbc17835a55101c87dae84463b0c931fcc6d5acb6a9a27190a37dd284d1e2175d4a5f0
6
+ metadata.gz: 3c8541239362433b39e376576b46469af9359982b1b8679dd7661e622510cd8be953bfbe0529b9b14b1f8695c172c5376e4f03b38fa4448dde1ea01ab90c2cff
7
+ data.tar.gz: 71da6ab478a3c8aa66dc5297df731906bbb34970360639dd9b5ae7fa4bb98c93ff3d043a1e2d70f2e01059178f6e8e3d99f6299cf8a9fe2109bf8e9dec52b332
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 4.2.4
4
+
5
+ - Exclude unnecessary files from the gem file list
6
+
7
+ ## 4.2.3
8
+
9
+ - Require MFA to publish gem
10
+
3
11
  ## 4.2.2
4
12
 
5
13
  - Faster CSV generation
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2006-2021 Keith Morrison <keithm@infused.org>
1
+ Copyright (c) 2006-2023 Keith Morrison <keithm@infused.org>
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -1,4 +1,5 @@
1
1
  # DBF
2
+
2
3
  [![Version](https://img.shields.io/gem/v/dbf.svg?style=flat)](https://rubygems.org/gems/dbf)
3
4
  [![Build Status](https://github.com/infused/dbf/actions/workflows/build.yml/badge.svg)](https://github.com/infused/dbf/actions/workflows/build.yml)
4
5
  [![Code Quality](https://img.shields.io/codeclimate/maintainability/infused/dbf.svg?style=flat)](https://codeclimate.com/github/infused/dbf)
@@ -6,8 +7,7 @@
6
7
  [![Total Downloads](https://img.shields.io/gem/dt/dbf.svg)](https://rubygems.org/gems/dbf/)
7
8
  [![License](https://img.shields.io/github/license/infused/dbf.svg)](https://github.com/infused/dbf)
8
9
 
9
- DBF is a small fast library for reading dBase, xBase, Clipper and FoxPro
10
- database files
10
+ DBF is a small, fast Ruby library for reading dBase, xBase, Clipper, and FoxPro database files.
11
11
 
12
12
  * Project page: <https://github.com/infused/dbf>
13
13
  * API Documentation: <https://dbf.infused.org>
@@ -16,23 +16,23 @@ database files
16
16
  subject line
17
17
  * Change log: <https://github.com/infused/dbf/blob/master/CHANGELOG.md>
18
18
 
19
- NOTE: Beginning with version 4 we have dropped support for Ruby 2.0, 2.1, 2.2, and 2.3. If you need support for these older Rubies,
20
- please use 3.0.x (https://github.com/infused.org/dbf/tree/3_stable)
19
+ NOTE: Beginning with version 4, we have dropped support for Ruby 2.0, 2.1, 2.2, and 2.3. If you need support for these older Rubies,
20
+ please use 3.0.x (<https://github.com/infused.org/dbf/tree/3_stable>)
21
21
 
22
- NOTE: Beginning with version 3 we have dropped support for Ruby 1.8 and 1.9. If you need support for older Rubies,
23
- please use 2.0.x (https://github.com/infused/dbf/tree/2_stable)
22
+ NOTE: Beginning with version 3, we have dropped support for Ruby 1.8 and 1.9. If you need support for older Rubies,
23
+ please use 2.0.x (<https://github.com/infused/dbf/tree/2_stable>)
24
24
 
25
25
  ## Compatibility
26
26
 
27
27
  DBF is tested to work with the following versions of Ruby:
28
28
 
29
- * Ruby 2.4.x, 2.5.x, 2.6.x, 2.7.x, 3.0.x, TruffleRuby
29
+ * Ruby 2.4.x, 2.5.x, 2.6.x, 2.7.x, 3.0.x, 3.1.x, and 3.2.x
30
30
 
31
31
  ## Installation
32
32
 
33
33
  Install the gem manually:
34
34
 
35
- ```
35
+ ```ruby
36
36
  gem install dbf
37
37
  ```
38
38
 
@@ -101,8 +101,7 @@ widget.attributes
101
101
  ```
102
102
 
103
103
  Search for records using a simple hash format. Multiple search criteria are
104
- ANDed. Use the block form if the resulting recordset could be large, otherwise
105
- all records will be loaded into memory.
104
+ ANDed. Use the block form if the resulting record set is too big. Otherwise, all records are loaded into memory.
106
105
 
107
106
  ```ruby
108
107
  # find all records with slot_number equal to s42
@@ -122,8 +121,7 @@ widgets.find(10)
122
121
 
123
122
  ## Enumeration
124
123
 
125
- DBF::Table is a Ruby Enumerable. This means you can use any Enumerable method.
126
- This means that you get a bunch of traversal, searching and sorting methods
124
+ DBF::Table is a Ruby Enumerable, so you get several traversal, search, and sort methods
127
125
  for free. For example, let's get only records created before January 1st, 2015:
128
126
 
129
127
  ```ruby
@@ -136,13 +134,9 @@ Or custom sorting:
136
134
  widgets.sort_by { |w| w.created_date }
137
135
  ```
138
136
 
139
-
140
137
  ## Encodings (Code Pages)
141
138
 
142
- dBase supports encoding non-english characters in different formats.
143
- Unfortunately, the format used is not always set, so you may have to specify it
144
- manually. For example, you have a DBF file from Russia and you are getting bad
145
- data. Try using the 'Russion OEM' encoding:
139
+ dBase supports encoding non-english characters with different character sets. Unfortunately, the character set used may not be set explicitly. In that case, you will have to specify it manually. For example, if you know the dbf file is encoded with 'Russian OEM':
146
140
 
147
141
  ```ruby
148
142
  table = DBF::Table.new('dbf/books.dbf', nil, 'cp866')
@@ -236,7 +230,7 @@ class CreateBooks < ActiveRecord::Migration
236
230
  end
237
231
  ```
238
232
 
239
- If you have initalized the DBF::Table with raw data, you will need to set the
233
+ If you have initialized the DBF::Table with raw data, you will need to set the
240
234
  exported table name manually:
241
235
 
242
236
  ```ruby
@@ -278,7 +272,7 @@ table.name = 'my_table_name'
278
272
 
279
273
  ## Command-line utility
280
274
 
281
- A small command-line utility called dbf is installed along with the gem.
275
+ A small command-line utility called dbf is installed with the gem.
282
276
 
283
277
  $ dbf -h
284
278
  usage: dbf [-h|-s|-a] filename
@@ -304,8 +298,7 @@ Dump all records to a CSV file:
304
298
  ## Reading a Visual Foxpro database (v8, v9)
305
299
 
306
300
  A special Database::Foxpro class is available to read Visual Foxpro container
307
- files (file with .dbc extension). When using this class long field names are
308
- supported and tables can be referenced without using names.
301
+ files (file with .dbc extension). When using this class, long field names are supported, and tables can be referenced without using names.
309
302
 
310
303
  ```ruby
311
304
  require 'dbf'
@@ -317,9 +310,9 @@ my_contact = contacts.record(1).spouses_interests
317
310
  ## dBase version compatibility
318
311
 
319
312
  The basic dBase data types are generally supported well. Support for the
320
- advanced data types in dbase V and FoxPro are still experimental or not
313
+ advanced data types in dBase V and FoxPro are still experimental or not
321
314
  supported. If you have insight into how any of the unsupported data types are
322
- implemented, please give me a shout. FoxBase/dBase II files are not supported
315
+ implemented, please open an issue on Github. FoxBase/dBase II files are not supported
323
316
  at this time.
324
317
 
325
318
  ### Supported data types by dBase version
@@ -369,7 +362,7 @@ Data type descriptions
369
362
 
370
363
  ## License
371
364
 
372
- Copyright (c) 2006-2021 Keith Morrison <<keithm@infused.org>>
365
+ Copyright (c) 2006-2023 Keith Morrison <<keithm@infused.org>>
373
366
 
374
367
  Permission is hereby granted, free of charge, to any person
375
368
  obtaining a copy of this software and associated documentation
data/dbf.gemspec CHANGED
@@ -15,9 +15,9 @@ Gem::Specification.new do |s|
15
15
  s.executables = ['dbf']
16
16
  s.rdoc_options = ['--charset=UTF-8']
17
17
  s.extra_rdoc_files = ['README.md', 'CHANGELOG.md', 'LICENSE']
18
- s.files = Dir['[A-Z]*', '{bin,docs,lib,spec}/**/*', 'dbf.gemspec']
19
- s.test_files = Dir.glob('spec/**/*_spec.rb')
18
+ s.files = Dir['README.md', 'CHANGELOG.md', 'LICENSE', '{bin,lib,spec}/**/*', 'dbf.gemspec']
20
19
  s.require_paths = ['lib']
21
20
  s.required_rubygems_version = Gem::Requirement.new('>= 1.3.0')
22
21
  s.required_ruby_version = Gem::Requirement.new('>= 2.4.0')
22
+ s.metadata['rubygems_mfa_required'] = 'true'
23
23
  end
data/lib/dbf/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module DBF
2
- VERSION = '4.2.2'.freeze
2
+ VERSION = '4.2.4'.freeze
3
3
  end
@@ -291,7 +291,7 @@ RSpec.describe DBF::Column do
291
291
  end
292
292
 
293
293
  it 'is truncated at the null character' do
294
- column = DBF::Column.new table, "--\x1F-\x68\x65\x6C\x6C\x6F \x00world-\x80--", 'N', 1, 0
294
+ column = DBF::Column.new table, "--\x1F-\x68\x65\x6C\x6C\x6F \x00world-\x80\x80--", 'N', 1, 0
295
295
  expect(column.name).to eq '---hello world---'
296
296
  end
297
297
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dbf
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.2
4
+ version: 4.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Keith Morrison
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-15 00:00:00.000000000 Z
11
+ date: 2023-05-30 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A small fast library for reading dBase, xBase, Clipper and FoxPro database
14
14
  files.
@@ -22,14 +22,9 @@ extra_rdoc_files:
22
22
  - LICENSE
23
23
  files:
24
24
  - CHANGELOG.md
25
- - Gemfile
26
- - Gemfile.lock
27
- - Guardfile
28
25
  - LICENSE
29
26
  - README.md
30
- - Rakefile
31
27
  - bin/dbf
32
- - ci_A.dbf
33
28
  - dbf.gemspec
34
29
  - lib/dbf.rb
35
30
  - lib/dbf/column.rb
@@ -45,7 +40,6 @@ files:
45
40
  - lib/dbf/schema.rb
46
41
  - lib/dbf/table.rb
47
42
  - lib/dbf/version.rb
48
- - nBOOKS.DBF
49
43
  - spec/dbf/column_spec.rb
50
44
  - spec/dbf/database/foxpro_spec.rb
51
45
  - spec/dbf/file_formats_spec.rb
@@ -99,7 +93,8 @@ files:
99
93
  homepage: http://github.com/infused/dbf
100
94
  licenses:
101
95
  - MIT
102
- metadata: {}
96
+ metadata:
97
+ rubygems_mfa_required: 'true'
103
98
  post_install_message:
104
99
  rdoc_options:
105
100
  - "--charset=UTF-8"
@@ -116,13 +111,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
116
111
  - !ruby/object:Gem::Version
117
112
  version: 1.3.0
118
113
  requirements: []
119
- rubygems_version: 3.3.7
114
+ rubygems_version: 3.4.13
120
115
  signing_key:
121
116
  specification_version: 4
122
117
  summary: Read xBase files
123
- test_files:
124
- - spec/dbf/column_spec.rb
125
- - spec/dbf/database/foxpro_spec.rb
126
- - spec/dbf/file_formats_spec.rb
127
- - spec/dbf/record_spec.rb
128
- - spec/dbf/table_spec.rb
118
+ test_files: []
data/Gemfile DELETED
@@ -1,17 +0,0 @@
1
- gemspec
2
- source 'https://rubygems.org'
3
-
4
- group :development, :test do
5
- gem 'awesome_print'
6
- gem 'byebug'
7
- gem 'e2mmap'
8
- gem 'guard'
9
- gem 'guard-rspec'
10
- gem 'irb'
11
- gem 'rake'
12
- gem 'rspec'
13
- gem 'rubocop'
14
- gem 'rubocop-performance'
15
- gem 'rubocop-rspec'
16
- gem 'yard'
17
- end
data/Gemfile.lock DELETED
@@ -1,114 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- dbf (4.2.1)
5
-
6
- GEM
7
- remote: https://rubygems.org/
8
- specs:
9
- ast (2.4.2)
10
- awesome_print (1.9.2)
11
- byebug (11.1.3)
12
- coderay (1.1.3)
13
- diff-lcs (1.5.0)
14
- e2mmap (0.1.0)
15
- ffi (1.15.5)
16
- formatador (1.1.0)
17
- guard (2.18.0)
18
- formatador (>= 0.2.4)
19
- listen (>= 2.7, < 4.0)
20
- lumberjack (>= 1.0.12, < 2.0)
21
- nenv (~> 0.1)
22
- notiffany (~> 0.0)
23
- pry (>= 0.13.0)
24
- shellany (~> 0.0)
25
- thor (>= 0.18.1)
26
- guard-compat (1.2.1)
27
- guard-rspec (4.7.3)
28
- guard (~> 2.1)
29
- guard-compat (~> 1.1)
30
- rspec (>= 2.99.0, < 4.0)
31
- io-console (0.5.11)
32
- irb (1.4.1)
33
- reline (>= 0.3.0)
34
- listen (3.7.1)
35
- rb-fsevent (~> 0.10, >= 0.10.3)
36
- rb-inotify (~> 0.9, >= 0.9.10)
37
- lumberjack (1.2.8)
38
- method_source (1.0.0)
39
- nenv (0.3.0)
40
- notiffany (0.1.3)
41
- nenv (~> 0.1)
42
- shellany (~> 0.0)
43
- parallel (1.22.1)
44
- parser (3.1.2.0)
45
- ast (~> 2.4.1)
46
- pry (0.14.1)
47
- coderay (~> 1.1)
48
- method_source (~> 1.0)
49
- rainbow (3.1.1)
50
- rake (13.0.6)
51
- rb-fsevent (0.11.1)
52
- rb-inotify (0.10.1)
53
- ffi (~> 1.0)
54
- regexp_parser (2.5.0)
55
- reline (0.3.1)
56
- io-console (~> 0.5)
57
- rexml (3.2.5)
58
- rspec (3.11.0)
59
- rspec-core (~> 3.11.0)
60
- rspec-expectations (~> 3.11.0)
61
- rspec-mocks (~> 3.11.0)
62
- rspec-core (3.11.0)
63
- rspec-support (~> 3.11.0)
64
- rspec-expectations (3.11.0)
65
- diff-lcs (>= 1.2.0, < 2.0)
66
- rspec-support (~> 3.11.0)
67
- rspec-mocks (3.11.1)
68
- diff-lcs (>= 1.2.0, < 2.0)
69
- rspec-support (~> 3.11.0)
70
- rspec-support (3.11.0)
71
- rubocop (1.30.1)
72
- parallel (~> 1.10)
73
- parser (>= 3.1.0.0)
74
- rainbow (>= 2.2.2, < 4.0)
75
- regexp_parser (>= 1.8, < 3.0)
76
- rexml (>= 3.2.5, < 4.0)
77
- rubocop-ast (>= 1.18.0, < 2.0)
78
- ruby-progressbar (~> 1.7)
79
- unicode-display_width (>= 1.4.0, < 3.0)
80
- rubocop-ast (1.18.0)
81
- parser (>= 3.1.1.0)
82
- rubocop-performance (1.14.2)
83
- rubocop (>= 1.7.0, < 2.0)
84
- rubocop-ast (>= 0.4.0)
85
- rubocop-rspec (2.11.1)
86
- rubocop (~> 1.19)
87
- ruby-progressbar (1.11.0)
88
- shellany (0.0.1)
89
- thor (1.2.1)
90
- unicode-display_width (2.1.0)
91
- webrick (1.7.0)
92
- yard (0.9.28)
93
- webrick (~> 1.7.0)
94
-
95
- PLATFORMS
96
- arm64-darwin-21
97
-
98
- DEPENDENCIES
99
- awesome_print
100
- byebug
101
- dbf!
102
- e2mmap
103
- guard
104
- guard-rspec
105
- irb
106
- rake
107
- rspec
108
- rubocop
109
- rubocop-performance
110
- rubocop-rspec
111
- yard
112
-
113
- BUNDLED WITH
114
- 2.3.20
data/Guardfile DELETED
@@ -1,11 +0,0 @@
1
- # A sample Guardfile
2
- # More info at https://github.com/guard/guard#readme
3
-
4
- guard :rspec, cmd: 'bundle exec rspec' do
5
- watch(%r{^spec/.+_spec\.rb$})
6
- # watch(%r{^lib/(.+)\.rb$}) { |m| "spec/#{m[1]}_spec.rb" }
7
- watch(%r{^lib/(.+)\.rb$}) { 'spec' }
8
- watch('spec/spec_helper.rb') { 'spec' }
9
- watch(%r{spec/fixtures/(.+)}) { 'spec' }
10
- watch('Guardfile') { 'spec' }
11
- end
data/Rakefile DELETED
@@ -1,18 +0,0 @@
1
- require 'bundler/setup'
2
- Bundler.setup(:default, :development)
3
-
4
- require 'rspec/core/rake_task'
5
- RSpec::Core::RakeTask.new :spec do |t|
6
- t.rspec_opts = %w[--color]
7
- end
8
-
9
- RSpec::Core::RakeTask.new :specdoc do |t|
10
- t.rspec_opts = %w[-fl]
11
- end
12
-
13
- task default: :spec
14
-
15
- desc 'Open an irb session preloaded with this library'
16
- task :console do
17
- sh 'irb -r rubygems -I lib -r dbf.rb'
18
- end
data/ci_A.dbf DELETED
Binary file
data/nBOOKS.DBF DELETED
Binary file