[devdocsgjs/main: 80/239] Update Chef documentation (17.9.18)




commit 193f2c2c58840d292af2f4f963ca0dad58ba8619
Author: Simon Legner <Simon Legner gmail com>
Date:   Mon Dec 27 17:39:48 2021 +0100

    Update Chef documentation (17.9.18)

 lib/docs/scrapers/chef.rb | 19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)
---
diff --git a/lib/docs/scrapers/chef.rb b/lib/docs/scrapers/chef.rb
index 45776ef3..04cdfa7e 100644
--- a/lib/docs/scrapers/chef.rb
+++ b/lib/docs/scrapers/chef.rb
@@ -20,6 +20,21 @@ module Docs
       We are not affiliated with, endorsed or sponsored by Chef Inc.
     HTML
 
+    version '17' do
+      self.release = '17.9.18'
+
+      options[:container] = '.off-canvas-wrapper'
+
+      options[:skip] = [
+        '/automate/api/',
+        '/habitat/supervisor_api/',
+        '/habitat/builder_api/'
+      ]
+
+      html_filters.push 'chef/entries', 'chef/clean_html'
+
+    end
+
     version '16' do
       self.release = '16.8.14'
 
@@ -82,8 +97,8 @@ module Docs
     end
 
     def get_latest_version(opts)
-      doc = fetch_doc('https://downloads.chef.io/products/infra', opts)
-      doc.at_css('#versions > option').content.strip
+      tags = get_github_tags('chef', 'chef', opts)
+      tags[0]['name'][1..-1]
     end
 
   end


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]