embulk-formatter-single_value 0.1.2 → 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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 541b2d9cb0b4e216d8e34f499dfbddea2a4f6757
|
4
|
+
data.tar.gz: 3fdbb979a054c104a4d91f474b73e2e195ee7448
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ceb2462967443de65d9a25d40ff2e62f0469d8b04a19627a490c6028806b647e1a4ed5244792e55c3b2b42da3bd928f8763b64072fffb5484acfae31e3bd6040
|
7
|
+
data.tar.gz: 1b6297f1046e071e3b43bac6d268ffe7f642af42fda4436064b7690236fc60144aa91016b10185c4ff59858144097fe609e547c0eb418ad2ffce7d7dd8632598
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -8,7 +8,7 @@ Embulk formatter plugin to output values of a single column. This is a kind of r
|
|
8
8
|
|
9
9
|
## Configuration
|
10
10
|
|
11
|
-
* **
|
11
|
+
* **column_name**: A column name which this plugin outputs (string, default: null which extracts the first column)
|
12
12
|
* **null_string**: A string value to express NULL value (string, default: "")
|
13
13
|
* **timestamp_format**: Timestamp format for timestamp column (string, default: "%Y-%m-%d %H:%M:%S.%6N %z")
|
14
14
|
* **timezone**: Timezone for timesatmp column (string, default: UTC)
|
@@ -20,7 +20,7 @@ out:
|
|
20
20
|
type: an output plugin supporting a formatter plugin such as `file`
|
21
21
|
formatter:
|
22
22
|
type: single_value
|
23
|
-
|
23
|
+
column_name: column1
|
24
24
|
null_string: ""
|
25
25
|
```
|
26
26
|
|
data/build.gradle
CHANGED
@@ -13,7 +13,7 @@ configurations {
|
|
13
13
|
provided
|
14
14
|
}
|
15
15
|
|
16
|
-
version = "0.
|
16
|
+
version = "0.2.0"
|
17
17
|
|
18
18
|
sourceCompatibility = 1.7
|
19
19
|
targetCompatibility = 1.7
|
@@ -73,7 +73,7 @@ task gemspec {
|
|
73
73
|
Gem::Specification.new do |spec|
|
74
74
|
spec.name = "${project.name}"
|
75
75
|
spec.version = "${project.version}"
|
76
|
-
spec.authors = ["
|
76
|
+
spec.authors = ["Naotoshi Seo"]
|
77
77
|
spec.summary = %[Embulk formatter plugin to output values of a single column]
|
78
78
|
spec.description = %[Embulk formatter plugin to output values of a single column.]
|
79
79
|
spec.email = ["sonots@gmail.com"]
|
data/example/example.yml
CHANGED
@@ -31,9 +31,9 @@ public class SingleValueFormatterPlugin
|
|
31
31
|
public interface PluginTask
|
32
32
|
extends Task, LineEncoder.EncoderTask, TimestampFormatter.Task
|
33
33
|
{
|
34
|
-
@Config("
|
34
|
+
@Config("column_name")
|
35
35
|
@ConfigDefault("null")
|
36
|
-
public Optional<String>
|
36
|
+
public Optional<String> getColumnName();
|
37
37
|
|
38
38
|
@Config("null_string")
|
39
39
|
@ConfigDefault("\"\"")
|
@@ -81,7 +81,7 @@ public class SingleValueFormatterPlugin
|
|
81
81
|
final LineEncoder encoder = new LineEncoder(output, task);
|
82
82
|
final String nullString = task.getNullString();
|
83
83
|
|
84
|
-
final int inputColumnIndex = getInputColumnIndex(task.
|
84
|
+
final int inputColumnIndex = getInputColumnIndex(task.getColumnName(), inputSchema);
|
85
85
|
final Schema outputSchema = getOutputSchema(inputColumnIndex, inputSchema);
|
86
86
|
final DateTimeZone timezone = DateTimeZone.forID(task.getTimezone());
|
87
87
|
final TimestampFormatter timestampFormatter =
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: embulk-formatter-single_value
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
-
-
|
7
|
+
- Naotoshi Seo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02-
|
11
|
+
date: 2016-02-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -52,11 +52,11 @@ files:
|
|
52
52
|
- build.gradle
|
53
53
|
- config/checkstyle/checkstyle.xml
|
54
54
|
- config/checkstyle/default.xml
|
55
|
+
- example/column_name.yml
|
55
56
|
- example/example.csv
|
56
57
|
- example/example.txt
|
57
58
|
- example/example.yml
|
58
59
|
- example/first_column.yml
|
59
|
-
- example/message_key.yml
|
60
60
|
- example/timestamp.txt
|
61
61
|
- example/timestamp.yml
|
62
62
|
- gradle/wrapper/gradle-wrapper.jar
|
@@ -66,7 +66,7 @@ files:
|
|
66
66
|
- lib/embulk/formatter/single_value.rb
|
67
67
|
- src/main/java/org/embulk/formatter/single_value/SingleValueFormatterPlugin.java
|
68
68
|
- src/test/java/org/embulk/formatter/single_value/TestSingleValueFormatterPlugin.java
|
69
|
-
- classpath/embulk-formatter-single_value-0.
|
69
|
+
- classpath/embulk-formatter-single_value-0.2.0.jar
|
70
70
|
homepage: https://github.com/sonots/embulk-formatter-single_value
|
71
71
|
licenses:
|
72
72
|
- MIT
|