Skip to content

Commit e6d8941

Browse files
committed
Update Vert.x documentation
1 parent 01aca6c commit e6d8941

File tree

3 files changed

+18
-6
lines changed

3 files changed

+18
-6
lines changed

assets/javascripts/news.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
[
2+
[
3+
"2025-05-28",
4+
"New documentation: <a href=\"/vertx/\">Vert.x</a>"
5+
],
26
[
37
"2025-02-23",
48
"New documentation: <a href=\"/threejs/\">Three.js</a>"

lib/docs/filters/vertx/clean_html.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ def call
2222

2323
# Remove code highlighting
2424
css('pre').each do |node|
25+
node['data-language'] = node.at_css('code')['data-lang'] if node.at_css('code')
2526
node.content = node.content
2627
end
2728

lib/docs/scrapers/vertx.rb

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
module Docs
22
class Vertx < UrlScraper
3+
self.name = 'Vert.x'
4+
self.slug = 'vertx'
35
self.type = 'vertx'
46
self.links = {
57
home: 'http://vertx.io',
@@ -21,19 +23,24 @@ class Vertx < UrlScraper
2123
/blog/,
2224
]
2325

24-
version '5.0.0' do
26+
version '5' do
2527
self.release = '5.0.0'
2628
self.base_url = "https://vertx.io/docs/"
2729
end
2830

29-
version '4.5.15' do
31+
version '4' do
3032
self.release = '4.5.15'
31-
self.base_url = "https://vertx.io/docs/#{self.version}"
33+
self.base_url = "https://vertx.io/docs/#{self.release}"
3234
end
3335

34-
version '3.9.16' do
35-
self.release = '4.5.15'
36-
self.base_url = "https://vertx.io/docs/#{self.version}"
36+
version '3' do
37+
self.release = '3.9.16'
38+
self.base_url = "https://vertx.io/docs/#{self.release}"
39+
end
40+
41+
def get_latest_version(opts)
42+
doc = fetch_doc('https://repo1.maven.org/maven2/io/vertx/vertx-stack-manager/maven-metadata.xml', opts)
43+
doc.css('version')[-1].text
3744
end
3845
end
3946
end

0 commit comments

Comments
 (0)