glitter 2.0.2 → 2.0.3

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
  SHA1:
3
- metadata.gz: 933224f234e6c794b126b62e609a7fc997cca493
4
- data.tar.gz: 473fa43aee7d10e862be6e22a143cd704419c26a
3
+ metadata.gz: a754f47c453fba3e6d232789d5a4ec5054eab365
4
+ data.tar.gz: 608eb756d583f1fd388e7e0dbdcdfa846f5fee18
5
5
  SHA512:
6
- metadata.gz: c81aa3d6de7b3bde56b491a3b05161c2be49711ab63193b391599d2346278552d2e0f415f7c479af325e8e5b77103e5fd5b43eda513a5b897ea52761b6f56d5c
7
- data.tar.gz: 581c3f5f89da167e88fb526045fc7a49135879063f7f8d04bc7f1f75c490218347e18639a64b2959d0a51b89c73d808b72849fe5d80628bf847c09849fbad222
6
+ metadata.gz: c00dc3b0fa33eb45e6c08ed73d84d9aa1eb0fd925ce9195611af71a21663704c7c908408b0f87fb5ee34a4eb3952407b6e5d4dacafeb12b8a50be22092af7d9a
7
+ data.tar.gz: e94f6023cdb4f593d9ed4c81d205911f99e67eb5bdab5528f9c239766fded93ab30845c4fe994dbfb4b564608a98d1fa0874b519ee457cf56dbbe5c5e6d9985f
@@ -5,7 +5,7 @@ module Glitter
5
5
  module Release
6
6
  # Break apart an S3 bucket key by /:channel/:version/:object-key
7
7
  def self.object_segments(key)
8
- if match = key.match(/\/?(.+)\/(.+)\/(.+)/)
8
+ if match = key.match(/\/?(.+?)\/(.+?)\/(.+)/)
9
9
  match.captures
10
10
  end
11
11
  end
@@ -23,7 +23,7 @@ module Glitter
23
23
  # respective released versions.
24
24
  def channel_versions
25
25
  bucket.objects.inject Hash.new { |h,k| h[k] = Set.new } do |hash, object|
26
- channel, version, _ = Release.object_segments(URI(object.url).path)
26
+ channel, version, _ = Release.object_segments(object.key)
27
27
  hash[channel].add(version) if channel and version
28
28
  hash
29
29
  end
@@ -1,3 +1,3 @@
1
1
  module Glitter
2
- VERSION = "2.0.2"
2
+ VERSION = "2.0.3"
3
3
  end
@@ -12,4 +12,18 @@ describe Glitter do
12
12
  r.notes = %[Did you know that its #{Time.now}? Wait, you can only answer yes to that question.]
13
13
  end.push.head
14
14
  end
15
+
16
+ it "AWS path segments are parsed correctly for an item at top level of version folder" do
17
+ channel, version, key = Glitter::Release.object_segments("/channel/version/some-item")
18
+ expect(channel).to eq("channel")
19
+ expect(version).to eq("version")
20
+ expect(key).to eq("some-item")
21
+ end
22
+
23
+ it "AWS path segments are parsed correctly for an item in subfolder of version folder" do
24
+ channel, version, key = Glitter::Release.object_segments("/channel/version/some-dir/some-item")
25
+ expect(channel).to eq("channel")
26
+ expect(version).to eq("version")
27
+ expect(key).to eq("some-dir/some-item")
28
+ end
15
29
  end
metadata CHANGED
@@ -1,55 +1,55 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glitter
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.2
4
+ version: 2.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brad Gessler, Thomas Hanley
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-11-13 00:00:00.000000000 Z
11
+ date: 2016-11-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: s3
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: haml
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - '>='
31
+ - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '0'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - '>='
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: thor
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '0'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
55
  description: Glitter makes it easy to publish software updates via the Sparkle framework
@@ -61,7 +61,7 @@ executables:
61
61
  extensions: []
62
62
  extra_rdoc_files: []
63
63
  files:
64
- - .gitignore
64
+ - ".gitignore"
65
65
  - Gemfile
66
66
  - Guardfile
67
67
  - README.md
@@ -88,17 +88,17 @@ require_paths:
88
88
  - lib
89
89
  required_ruby_version: !ruby/object:Gem::Requirement
90
90
  requirements:
91
- - - '>='
91
+ - - ">="
92
92
  - !ruby/object:Gem::Version
93
93
  version: '0'
94
94
  required_rubygems_version: !ruby/object:Gem::Requirement
95
95
  requirements:
96
- - - '>='
96
+ - - ">="
97
97
  - !ruby/object:Gem::Version
98
98
  version: '0'
99
99
  requirements: []
100
100
  rubyforge_project: glitter
101
- rubygems_version: 2.1.10
101
+ rubygems_version: 2.6.8
102
102
  signing_key:
103
103
  specification_version: 4
104
104
  summary: Publish Mac software updates with the Sparkle framework and Amazon S3.