smart_csv_import 0.1.0 → 0.2.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 +4 -4
- data/README.md +30 -3
- data/lib/generators/smart_csv_import/import/templates/import_form.rb.tt +1 -1
- data/lib/generators/smart_csv_import/install/templates/create_smart_csv_import_import_row_errors.rb.tt +3 -1
- data/lib/smart_csv_import/version.rb +1 -1
- data/smart_csv_import.gemspec +4 -4
- metadata +9 -9
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 87c6acce723a52e407a3af9d27aec76b1e3afc4367631d353e10521307216f04
|
|
4
|
+
data.tar.gz: e2355037684212d67b602638f145844465bed7e45e22cdf539a76afb76831c08
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: bf6f29a71bffeb2fce2dc7609a0b94394d35a0de51e39c3a6aac0adc31b4e0eac839d6dfb1dc8a7efb49b68383d57f4031a10ae0c4c1e9721c04987894990d97
|
|
7
|
+
data.tar.gz: a9622bda510998deed07bb8f74688b09680b25fe4ee3e315dcbc1a03f2e8adfa092c3d276fa50a96d4185741db6e501e0e21d3b809614d6ac151f99df72c3330
|
data/README.md
CHANGED
|
@@ -47,15 +47,28 @@ end
|
|
|
47
47
|
|
|
48
48
|
### 2. Install the gem
|
|
49
49
|
|
|
50
|
+
Add to your Gemfile:
|
|
51
|
+
|
|
50
52
|
```ruby
|
|
51
|
-
|
|
52
|
-
gem "smart_csv_import"
|
|
53
|
+
gem "smart_csv_import", "~> 0.1"
|
|
53
54
|
```
|
|
54
55
|
|
|
56
|
+
Then:
|
|
57
|
+
|
|
55
58
|
```bash
|
|
56
59
|
bundle install
|
|
57
60
|
```
|
|
58
61
|
|
|
62
|
+
Or install directly:
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
gem install smart_csv_import
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
```ruby
|
|
69
|
+
require "smart_csv_import"
|
|
70
|
+
```
|
|
71
|
+
|
|
59
72
|
### 3. Run the install generator
|
|
60
73
|
|
|
61
74
|
```bash
|
|
@@ -66,7 +79,8 @@ This creates:
|
|
|
66
79
|
|
|
67
80
|
- `config/initializers/smart_csv_import.rb` — configuration with all options commented out at their defaults
|
|
68
81
|
- `db/migrate/YYYYMMDDHHMMSS_create_smart_csv_import_imports.rb` — import tracking table
|
|
69
|
-
- `
|
|
82
|
+
- `db/migrate/YYYYMMDDHHMMSS_create_smart_csv_import_import_row_errors.rb` — per-row failure tracking table (referenced by `Import#row_errors`)
|
|
83
|
+
- `tmp/smart_csv_import/imports/` and `tmp/smart_csv_import/embeddings_cache/` — storage directories
|
|
70
84
|
|
|
71
85
|
```bash
|
|
72
86
|
rails db:migrate
|
|
@@ -529,6 +543,19 @@ Before sending a PR that touches the matching strategies, read [`ROADMAP.md`](RO
|
|
|
529
543
|
|
|
530
544
|
---
|
|
531
545
|
|
|
546
|
+
## Releasing
|
|
547
|
+
|
|
548
|
+
This gem follows the [Gemsmith](https://www.alchemists.io/projects/gemsmith) and [Milestoner](https://www.alchemists.io/projects/milestoner) conventions.
|
|
549
|
+
|
|
550
|
+
1. Tests pass: `bundle exec rake`
|
|
551
|
+
2. Bump `lib/smart_csv_import/version.rb` and `CITATION.cff`
|
|
552
|
+
3. Add a new `== X.Y.Z (YYYY-MM-DD)` section to `VERSIONS.adoc` summarising the changes
|
|
553
|
+
4. Commit using a [Git Lint](https://www.alchemists.io/projects/git-lint) subject (e.g. `Added Foo`) with a `Milestone:` trailer (`major`, `minor`, or `patch`) — Milestoner reads these trailers to compute the next version
|
|
554
|
+
5. `milestoner --publish X.Y.Z` (creates and pushes the annotated tag built from commit history)
|
|
555
|
+
6. `gemsmith --publish` (builds the gem, pushes to RubyGems — will prompt for MFA OTP)
|
|
556
|
+
|
|
557
|
+
---
|
|
558
|
+
|
|
532
559
|
## License
|
|
533
560
|
|
|
534
561
|
[MIT](LICENSE.adoc)
|
|
@@ -13,6 +13,8 @@ class CreateSmartCsvImportImportRowErrors < ActiveRecord::Migration[<%= ActiveRe
|
|
|
13
13
|
t.datetime :created_at, null: false
|
|
14
14
|
end
|
|
15
15
|
|
|
16
|
-
add_index :smart_csv_import_import_row_errors,
|
|
16
|
+
add_index :smart_csv_import_import_row_errors,
|
|
17
|
+
[:import_id, :error_type, :row_number],
|
|
18
|
+
name: "idx_scsi_row_errors_lookup"
|
|
17
19
|
end
|
|
18
20
|
end
|
data/smart_csv_import.gemspec
CHANGED
|
@@ -22,10 +22,10 @@ Gem::Specification.new do |spec|
|
|
|
22
22
|
|
|
23
23
|
spec.required_ruby_version = ">= 3.1"
|
|
24
24
|
|
|
25
|
-
spec.add_dependency "activemodel", ">=
|
|
26
|
-
spec.add_dependency "activerecord", ">=
|
|
27
|
-
spec.add_dependency "activejob", ">=
|
|
28
|
-
spec.add_dependency "activesupport", ">=
|
|
25
|
+
spec.add_dependency "activemodel", ">= 6.1", "< 9"
|
|
26
|
+
spec.add_dependency "activerecord", ">= 6.1", "< 9"
|
|
27
|
+
spec.add_dependency "activejob", ">= 6.1", "< 9"
|
|
28
|
+
spec.add_dependency "activesupport", ">= 6.1", "< 9"
|
|
29
29
|
spec.add_dependency "csv", "~> 3.0"
|
|
30
30
|
spec.add_dependency "smarter_csv", "~> 1.10"
|
|
31
31
|
spec.add_dependency "ruby_llm", "~> 1.0"
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: smart_csv_import
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Nico Roulston
|
|
@@ -15,7 +15,7 @@ dependencies:
|
|
|
15
15
|
requirements:
|
|
16
16
|
- - ">="
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
|
-
version: '
|
|
18
|
+
version: '6.1'
|
|
19
19
|
- - "<"
|
|
20
20
|
- !ruby/object:Gem::Version
|
|
21
21
|
version: '9'
|
|
@@ -25,7 +25,7 @@ dependencies:
|
|
|
25
25
|
requirements:
|
|
26
26
|
- - ">="
|
|
27
27
|
- !ruby/object:Gem::Version
|
|
28
|
-
version: '
|
|
28
|
+
version: '6.1'
|
|
29
29
|
- - "<"
|
|
30
30
|
- !ruby/object:Gem::Version
|
|
31
31
|
version: '9'
|
|
@@ -35,7 +35,7 @@ dependencies:
|
|
|
35
35
|
requirements:
|
|
36
36
|
- - ">="
|
|
37
37
|
- !ruby/object:Gem::Version
|
|
38
|
-
version: '
|
|
38
|
+
version: '6.1'
|
|
39
39
|
- - "<"
|
|
40
40
|
- !ruby/object:Gem::Version
|
|
41
41
|
version: '9'
|
|
@@ -45,7 +45,7 @@ dependencies:
|
|
|
45
45
|
requirements:
|
|
46
46
|
- - ">="
|
|
47
47
|
- !ruby/object:Gem::Version
|
|
48
|
-
version: '
|
|
48
|
+
version: '6.1'
|
|
49
49
|
- - "<"
|
|
50
50
|
- !ruby/object:Gem::Version
|
|
51
51
|
version: '9'
|
|
@@ -55,7 +55,7 @@ dependencies:
|
|
|
55
55
|
requirements:
|
|
56
56
|
- - ">="
|
|
57
57
|
- !ruby/object:Gem::Version
|
|
58
|
-
version: '
|
|
58
|
+
version: '6.1'
|
|
59
59
|
- - "<"
|
|
60
60
|
- !ruby/object:Gem::Version
|
|
61
61
|
version: '9'
|
|
@@ -65,7 +65,7 @@ dependencies:
|
|
|
65
65
|
requirements:
|
|
66
66
|
- - ">="
|
|
67
67
|
- !ruby/object:Gem::Version
|
|
68
|
-
version: '
|
|
68
|
+
version: '6.1'
|
|
69
69
|
- - "<"
|
|
70
70
|
- !ruby/object:Gem::Version
|
|
71
71
|
version: '9'
|
|
@@ -75,7 +75,7 @@ dependencies:
|
|
|
75
75
|
requirements:
|
|
76
76
|
- - ">="
|
|
77
77
|
- !ruby/object:Gem::Version
|
|
78
|
-
version: '
|
|
78
|
+
version: '6.1'
|
|
79
79
|
- - "<"
|
|
80
80
|
- !ruby/object:Gem::Version
|
|
81
81
|
version: '9'
|
|
@@ -85,7 +85,7 @@ dependencies:
|
|
|
85
85
|
requirements:
|
|
86
86
|
- - ">="
|
|
87
87
|
- !ruby/object:Gem::Version
|
|
88
|
-
version: '
|
|
88
|
+
version: '6.1'
|
|
89
89
|
- - "<"
|
|
90
90
|
- !ruby/object:Gem::Version
|
|
91
91
|
version: '9'
|