Class: Debci::HTML::Feed
Instance Attribute Summary
Attributes inherited from Rooted
#root
Instance Method Summary
collapse
Methods inherited from Rooted
#initialize, #repository
Instance Method Details
#datadir ⇒ Object
196
197
198
|
# File 'lib/debci/html.rb', line 196
def datadir
'feeds'
end
|
#global ⇒ Object
200
201
202
203
204
205
206
207
208
209
210
211
|
# File 'lib/debci/html.rb', line 200
def global
global_news = repository.global_news(50)
write_feed(global_news, root / 'all-packages.xml') do |feed|
feed.channel.title = "#{Debci.config.distro_name} CI news"
feed.channel.about = Debci.config.url_base
feed.channel.description = [
'News about all packages.',
'Includes only state transitions (pass-fail, fail-pass).',
'Full history is available in each individual package page and in their published data files.',
].join(' ')
end
end
|
#package(pkg) ⇒ Object
213
214
215
216
217
218
219
220
221
222
223
224
|
# File 'lib/debci/html.rb', line 213
def package(pkg)
news = repository.news_for(pkg)
write_feed(news, root / pkg.prefix / "#{pkg.name}.xml") do |feed|
feed.channel.title = "#{pkg.name} CI news feed"
feed.channel.about = Debci.config.url_base + "/packages/#{pkg.prefix}/#{pkg.name}/"
feed.channel.description = [
"News for #{pkg.name}.",
'Includes only state transitions (pass-fail, and fail-pass).',
'Full history is available in the package page and in the published data files.',
].join(' ')
end
end
|