brick_ftp 0.7.1 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +21 -2
- data/lib/brick_ftp/api/base.rb +7 -2
- data/lib/brick_ftp/api/file_operation/uploading_session.rb +10 -0
- data/lib/brick_ftp/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7b5f39154f9f9cb909e38e0a7b3b20e7da36921d348340f21186b272cc06332b
|
4
|
+
data.tar.gz: 1cda57b5a7f2c3170ec94cbda3dc0c545a056aab7a1fb1893aed5ef0382d87d8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c678bfe33641ef68904283954d8fab9c8756b75265798fe53bec129fb7c65a30259a954fb894e3d029ded471d37b98d268a8d5f860d404e5d3a320f4b082c563
|
7
|
+
data.tar.gz: 508b6cdb4d5c1f7e250d2ffe48fd966d87add82ae8e33538d7b7f8c99cee5c5f08af67b05b3d2ba5ef7ca8d183829727b96576aa0e7589bc9620398450743ab7
|
data/CHANGELOG.md
CHANGED
@@ -2,10 +2,10 @@ Changelog
|
|
2
2
|
====
|
3
3
|
|
4
4
|
|
5
|
-
[unreleased](https://github.com/koshigoe/brick_ftp/compare/v0.
|
5
|
+
[unreleased](https://github.com/koshigoe/brick_ftp/compare/v0.8.0...master)
|
6
6
|
----
|
7
7
|
|
8
|
-
[Full Changelog](https://github.com/koshigoe/brick_ftp/compare/v0.
|
8
|
+
[Full Changelog](https://github.com/koshigoe/brick_ftp/compare/v0.8.0...master)
|
9
9
|
|
10
10
|
### Enhancements:
|
11
11
|
|
@@ -14,6 +14,25 @@ Changelog
|
|
14
14
|
### Breaking Changes:
|
15
15
|
|
16
16
|
|
17
|
+
[v0.8.0](https://github.com/koshigoe/brick_ftp/compare/v0.7.1...v0.8.0)
|
18
|
+
----
|
19
|
+
|
20
|
+
[Full Changelog](https://github.com/koshigoe/brick_ftp/compare/v0.7.1...v0.8.0)
|
21
|
+
|
22
|
+
### Enhancements:
|
23
|
+
|
24
|
+
### Fixed Bugs:
|
25
|
+
|
26
|
+
- [#92](https://github.com/koshigoe/brick_ftp/pull/92) Re-Overwrite `as_json` to avoid to too much loop.
|
27
|
+
- fixes [#91](https://github.com/koshigoe/brick_ftp/issues/91)
|
28
|
+
|
29
|
+
### Breaking Changes:
|
30
|
+
|
31
|
+
- [#92](https://github.com/koshigoe/brick_ftp/pull/92)
|
32
|
+
- Change type of key of returned Hash object from `BrickFTP::API::Base#as_json` to `String`.
|
33
|
+
- Initialize `BrickFTP::API::Base#properties` with all defined attributes.
|
34
|
+
|
35
|
+
|
17
36
|
[v0.7.1](https://github.com/koshigoe/brick_ftp/compare/v0.7.0...v0.7.1)
|
18
37
|
----
|
19
38
|
|
data/lib/brick_ftp/api/base.rb
CHANGED
@@ -43,7 +43,7 @@ module BrickFTP
|
|
43
43
|
attr_reader :properties
|
44
44
|
|
45
45
|
def initialize(params = {})
|
46
|
-
|
46
|
+
initialize_properties
|
47
47
|
params.each { |k, v| write_property(k, v) }
|
48
48
|
end
|
49
49
|
|
@@ -73,7 +73,7 @@ module BrickFTP
|
|
73
73
|
end
|
74
74
|
|
75
75
|
def as_json
|
76
|
-
|
76
|
+
properties.dup
|
77
77
|
end
|
78
78
|
|
79
79
|
def to_json
|
@@ -94,6 +94,11 @@ module BrickFTP
|
|
94
94
|
|
95
95
|
private
|
96
96
|
|
97
|
+
def initialize_properties
|
98
|
+
@properties = {}
|
99
|
+
self.class.attributes.each { |key| write_property(key, nil) }
|
100
|
+
end
|
101
|
+
|
97
102
|
def respond_to_missing?(method_name, _include_private)
|
98
103
|
self.class.attributes.include?(method_name.to_sym)
|
99
104
|
end
|
@@ -79,6 +79,16 @@ module BrickFTP
|
|
79
79
|
def commit
|
80
80
|
UploadingResult.create(path: path, ref: ref)
|
81
81
|
end
|
82
|
+
|
83
|
+
# Return single uploading session object.
|
84
|
+
#
|
85
|
+
# NOTE: The `#as_json` method will be overwritten by active_supprt.
|
86
|
+
#
|
87
|
+
# @return [Hash] a JSON serializable object
|
88
|
+
#
|
89
|
+
def as_json
|
90
|
+
properties.dup
|
91
|
+
end
|
82
92
|
end
|
83
93
|
end
|
84
94
|
end
|
data/lib/brick_ftp/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: brick_ftp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- koshigoe
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-01-
|
11
|
+
date: 2018-01-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|