Update Ansible scrapers

pull/1297/head
Phil Scherer 4 years ago
parent 18f5c0ac37
commit ca3b54f566

@ -7,6 +7,13 @@ module Docs
name.remove! %r{ \- .*} name.remove! %r{ \- .*}
name.remove! 'Introduction To ' name.remove! 'Introduction To '
name.remove! %r{ Guide\z} name.remove! %r{ Guide\z}
if version == "2.10"
if slug =~ /\Acollections\// and slug !~ /index$/
name = name.split('.')[2]
end
end
name name
end end
@ -21,6 +28,12 @@ module Docs
end end
end end
if version == "2.10"
if slug =~ /\Acollections\//
return "Collection #{slug.split('/')[1..-2].join(".")}"
end
end
if slug =~ /\Acli\// if slug =~ /\Acli\//
'CLI Reference' 'CLI Reference'
elsif slug =~ /\Anetwork\// elsif slug =~ /\Anetwork\//

@ -30,18 +30,23 @@ module Docs
/\Aroadmap.*/i, /\Aroadmap.*/i,
] ]
version '2.10' do
self.release = '2.10.3'
self.base_url = "https://docs.ansible.com/ansible/#{version}/"
end
version '2.9' do version '2.9' do
self.release = '2.9.1' self.release = '2.9.15'
self.base_url = "https://docs.ansible.com/ansible/#{version}/" self.base_url = "https://docs.ansible.com/ansible/#{version}/"
end end
version '2.8' do version '2.8' do
self.release = '2.8.7' self.release = '2.8.16'
self.base_url = "https://docs.ansible.com/ansible/#{version}/" self.base_url = "https://docs.ansible.com/ansible/#{version}/"
end end
version '2.7' do version '2.7' do
self.release = '2.7.15' self.release = '2.7.17'
self.base_url = "https://docs.ansible.com/ansible/#{version}/" self.base_url = "https://docs.ansible.com/ansible/#{version}/"
end end

Loading…
Cancel
Save