2021-12-27 20:12:07 +01:00
|
|
|
|
module Docs
|
|
|
|
|
class Zig < UrlScraper
|
|
|
|
|
self.name = 'Zig'
|
|
|
|
|
self.type = 'simple'
|
2022-11-04 22:12:53 +01:00
|
|
|
|
self.release = '0.10.0'
|
|
|
|
|
self.base_url = "https://ziglang.org/documentation/#{self.release}/"
|
2021-12-27 20:12:07 +01:00
|
|
|
|
self.links = {
|
|
|
|
|
home: 'https://ziglang.org/',
|
|
|
|
|
code: 'https://github.com/ziglang/zig'
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
html_filters.push 'zig/entries', 'zig/clean_html'
|
|
|
|
|
|
|
|
|
|
options[:follow_links] = false
|
|
|
|
|
options[:attribution] = <<-HTML
|
2022-11-04 22:12:53 +01:00
|
|
|
|
© 2015–2022, Zig contributors
|
2021-12-27 20:12:07 +01:00
|
|
|
|
HTML
|
|
|
|
|
|
|
|
|
|
def get_latest_version(opts)
|
|
|
|
|
tags = get_github_tags('ziglang', 'zig', opts)
|
|
|
|
|
tags[0]['name']
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
end
|