ognivo 0.0.2 → 0.0.3

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: 92a20aed7af529b09b1e7c5bd83e3fd89c199206
4
- data.tar.gz: 35a0ee3a07c6a53c4b17e194a44855bb516f18c5
3
+ metadata.gz: 0afb2d97c612bb7d4496268cc08c8fb21fafa8c3
4
+ data.tar.gz: a5fa29a32be9990c1914cfe56fe8de83a2d0336d
5
5
  SHA512:
6
- metadata.gz: 59988a1b2eb5d28841b075194837e7f4a854610765e053ea250da959c70f330a5a8b6359e45ce042577c0b65a92510c480352d05c603e983b4a29f4fb1a65c42
7
- data.tar.gz: d992bff5a7530fac6c1cee9ea4bfa0a35c1d659dd02ffc3aae8b47ca177757a5c43e7eac1a7aaf0078e53f694fec91aba4d1f147d659bb0f4972fe75e687d148
6
+ metadata.gz: 859987f3490cfe8ecfb704fb6f2e2c95f590883517d49dd84101b516a3321d4f2653e7744846f3b93d858c85d4a8f9b2ecfad85ee8cc954788e4f88012ba625f
7
+ data.tar.gz: 2428155a402dff2d6a566bd71223d369f0c8e6310108b535ad278b071068eb65c978eba4ceae93b2cba58a9ae5ae7da9edbcf68b5a23baa78bc5ad08b2a7fe32
data/README.md CHANGED
@@ -64,6 +64,8 @@ you can specify DSA private key to calculate code signature for Sparkle using
64
64
  Read more about code signing
65
65
  [here](https://github.com/sparkle-project/Sparkle/wiki#3-segue-for-security-concerns).
66
66
 
67
+ > In order to use Sparkle's DSA build signing feature you must install `openssl`.
68
+
67
69
  ### Releasing an update
68
70
 
69
71
  Most of the time you will use `release` command, that builds a new version and
data/lib/ognivo.rb CHANGED
@@ -1,6 +1,5 @@
1
1
  require 'ognivo/version'
2
2
 
3
- require 'ognivo/appcast'
4
3
  require 'ognivo/utils'
5
4
 
6
5
  require 'ognivo/cli_helpers'
data/lib/ognivo/upload.rb CHANGED
@@ -1,3 +1,4 @@
1
+ require 'sparklecast'
1
2
  require 'redcarpet'
2
3
 
3
4
  module Ognivo
@@ -48,7 +49,9 @@ module Ognivo
48
49
  end
49
50
 
50
51
  def create_cast
51
- cast = Appcast.new(cast_title, cast_link, cast_description, cast_language)
52
+ cast = Sparklecast::Appcast.new(
53
+ cast_title, cast_link, cast_description, cast_language
54
+ )
52
55
 
53
56
  data = cast.generate
54
57
 
@@ -103,8 +106,8 @@ module Ognivo
103
106
  end
104
107
 
105
108
  def create_item
106
- say 'lets create an update entry'
107
- item = Appcast::Item.new(item_title, item_description, item_version)
109
+ say "Let's create an update entry"
110
+ item = Sparklecast::Appcast::Item.new(item_title, item_description, item_version)
108
111
  item.url = item_url
109
112
  item.type = 'application/octet-stream'
110
113
 
@@ -116,7 +119,7 @@ module Ognivo
116
119
  def add_item_to_app_cast(item)
117
120
  xml = s3_client.read(@appcast_name)
118
121
 
119
- new_xml = Appcast.add_item(xml, item)
122
+ new_xml = Sparklecast::Appcast.add_item(xml, item)
120
123
 
121
124
  s3_client.upload(new_xml, @appcast_name)
122
125
  end
@@ -1,3 +1,3 @@
1
1
  module Ognivo
2
- VERSION = '0.0.2'
2
+ VERSION = '0.0.3'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ognivo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anatoliy Plastinin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-17 00:00:00.000000000 Z
11
+ date: 2014-10-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: commander
@@ -39,7 +39,7 @@ dependencies:
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
- name: nokogiri
42
+ name: sparklecast
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - ">="
@@ -107,7 +107,6 @@ files:
107
107
  - README.md
108
108
  - bin/spark
109
109
  - lib/ognivo.rb
110
- - lib/ognivo/appcast.rb
111
110
  - lib/ognivo/build.rb
112
111
  - lib/ognivo/cli.rb
113
112
  - lib/ognivo/cli_helpers.rb
@@ -139,7 +138,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
139
138
  version: '0'
140
139
  requirements: []
141
140
  rubyforge_project:
142
- rubygems_version: 2.4.1
141
+ rubygems_version: 2.4.2
143
142
  signing_key:
144
143
  specification_version: 4
145
144
  summary: Ognivo
@@ -1,71 +0,0 @@
1
- require 'nokogiri'
2
-
3
- module Ognivo
4
- class Appcast
5
- class Item < Struct.new(:title, :description, :sparkle_version, :pub_date, :url,
6
- :length, :type, :dsa_signature)
7
- def to_node(xml)
8
- xml.item do
9
- xml.title title
10
- xml.description do
11
- xml.cdata description
12
- end
13
- xml.pubDate pub_date.rfc2822
14
- xml.enclosure enclosure
15
- end
16
- end
17
-
18
- private
19
-
20
- def enclosure
21
- {
22
- 'url' => url,
23
- 'sparkle:version' => sparkle_version,
24
- 'length' => length,
25
- 'type' => type,
26
- 'sparkle:dsaSignature' => dsa_signature
27
- }.reject { |_, v| v.nil? }
28
- end
29
- end
30
-
31
- attr_accessor :title
32
- attr_accessor :link
33
- attr_accessor :description
34
- attr_accessor :language
35
-
36
- RSS_ATTRIBUTES = {
37
- 'version' => '2.0',
38
- 'xmlns:sparkle' => 'http://www.andymatuschak.org/xml-namespaces/sparkle',
39
- 'xmlns:dc' => 'http://purl.org/dc/elements/1.1/'
40
- }
41
-
42
- def initialize(title, link, description, language)
43
- @title = title
44
- @link = link
45
- @description = description
46
- @language = language
47
- end
48
-
49
- def generate
50
- Nokogiri::XML::Builder.new(encoding: 'utf-8') do |xml|
51
- xml.rss(RSS_ATTRIBUTES) do
52
- xml.channel do
53
- xml.title title
54
- xml.link link
55
- xml.description description
56
- xml.language language
57
- end
58
- end
59
- end.to_xml
60
- end
61
-
62
- def self.add_item(xml_text, item)
63
- doc = Nokogiri::XML(xml_text) { |cfg| cfg.noblanks }
64
- Nokogiri::XML::Builder.with(doc.at('channel')) do |xml|
65
- item.to_node(xml)
66
- end
67
-
68
- doc.to_xml
69
- end
70
- end
71
- end