History

Merge pull request #1629 from freeCodeCamp/postgresql-14

Update PostgreSQL documentation (14.0)

Simon Legner committed 5 years ago

Commit f73e4422 parents 75dca09 d0555952 files · +9 −10Browse files

Unified · Split

2 files
  1. lib/docs/filters/postgresql/entries.rb +3 −9
  2. lib/docs/scrapers/postgresql.rb +6 −1
lib/docs/filters/postgresql/entries.rb+3−9
@@ -100,21 +100,14 @@ module Docs · 99 unmodified lines
100 when 'queries-table-expressions'100 when 'queries-table-expressions'
101 entries.concat get_heading_entries('h3[id], .sect3[id] > h3:first-child')101 entries.concat get_heading_entries('h3[id], .sect3[id] > h3:first-child')
102 entries.concat get_custom_entries('dt > .literal:first-child')102 entries.concat get_custom_entries('dt > .literal:first-child')
103 when 'functions-logical'
104 entries.concat get_custom_entries('> table td:first-child > code')
105 when 'functions-formatting'
106 entries.concat get_custom_entries('#FUNCTIONS-FORMATTING-TABLE td:first-child > code')
107 when 'functions-admin'103 when 'functions-admin'
108 entries.concat get_custom_entries('.table td:first-child > code')104 entries.concat get_custom_entries('.table td:first-child > p:first-child > code.function')
109 when 'functions-string'
110 entries.concat get_custom_entries('> div[id^="FUNC"] td:first-child > code')
111 entries.concat get_custom_entries('> div[id^="FORMAT"] td:first-child > code')
112 else105 else
113 if type && type.start_with?('Functions')106 if type && type.start_with?('Functions')
114 entries.concat get_custom_entries('> .table td:first-child > code.literal:first-child')107 entries.concat get_custom_entries('> .table td:first-child > code.literal:first-child')
115 entries.concat get_custom_entries('> .table td:first-child > code.function:first-child')108 entries.concat get_custom_entries('> .table td:first-child > code.function:first-child')
116 entries.concat get_custom_entries('> .table td:first-child > code:not(.literal):first-child + code.literal')109 entries.concat get_custom_entries('> .table td:first-child > code:not(.literal):first-child + code.literal')
117 entries.concat get_custom_entries('> .table td:first-child > p > code.literal:first-child')110 entries.concat get_custom_entries('> .table td:first-child > p:first-child > code.literal:first-child')
118 entries.concat get_custom_entries('> .table td:first-child > p > code.function:first-child')111 entries.concat get_custom_entries('> .table td:first-child > p > code.function:first-child')
119 entries.concat get_custom_entries('> .table td:first-child > p > code:not(.literal):first-child + code.literal')112 entries.concat get_custom_entries('> .table td:first-child > p > code:not(.literal):first-child + code.literal')
120 if slug == 'functions-comparison' && !at_css('#FUNCTIONS-COMPARISON-PRED-TABLE') # before 9.6113 if slug == 'functions-comparison' && !at_css('#FUNCTIONS-COMPARISON-PRED-TABLE') # before 9.6
@@ -220,6 +213,7 @@ module Docs · 99 unmodified lines
220 unless entries.any? { |entry| entry[0] == name }213 unless entries.any? { |entry| entry[0] == name }
221 node['id'] = id214 node['id'] = id
222 entries << [name, id]215 entries << [name, id]
216 # puts [selector, name].join(' --> ')
223 end217 end
224 end218 end
225 end219 end
lib/docs/scrapers/postgresql.rb+6−1
@@ -55,8 +55,13 @@ module Docs · 54 unmodified lines
55 Licensed under the PostgreSQL License.55 Licensed under the PostgreSQL License.
56 HTML56 HTML
57 57
58 version '14' do
59 self.release = '14.0'
60 self.base_url = "https://www.postgresql.org/docs/#{version}/"
61 end
62
58 version '13' do63 version '13' do
59 self.release = '13.2'64 self.release = '13.4'
60 self.base_url = "https://www.postgresql.org/docs/#{version}/"65 self.base_url = "https://www.postgresql.org/docs/#{version}/"
61 end66 end
62 67