From 080faaed4acd03651201f029e981188e8308b233 Mon Sep 17 00:00:00 2001 From: Saivann Date: Fri, 31 Jan 2014 13:41:09 -0500 Subject: [PATCH] Use https urls in sitemap file --- _plugins/sitemap.rb | 12 ++++++------ robots.txt | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/_plugins/sitemap.rb b/_plugins/sitemap.rb index ef86974da8..f27deb8182 100644 --- a/_plugins/sitemap.rb +++ b/_plugins/sitemap.rb @@ -46,7 +46,7 @@ def generate(site) next if locs[lang]['url'][id].nil? or locs[lang]['url'][id] == '' next if redirects.has_key?(id) and ( !redirects[id].has_key?('except') or !redirects[id]['except'].has_key?(lang) ) sitemap.puts '' - sitemap.puts ' http://bitcoin.org/'+lang+'/'+CGI::escape(locs[lang]['url'][id])+'' + sitemap.puts ' https://bitcoin.org/'+lang+'/'+CGI::escape(locs[lang]['url'][id])+'' locs.each do |altlang,value| altid = id #If there is a redirection from this page, use the destination as alternate url @@ -61,7 +61,7 @@ def generate(site) sitemap.puts ' ' + sitemap.puts ' href="https://bitcoin.org/'+altlang+'/'+CGI::escape(locs[altlang]['url'][altid])+'" />' end sitemap.puts '' end @@ -75,7 +75,7 @@ def generate(site) data = File.read(file1+'/'+file2) next if !data.index('window.location.href=').nil? or !data.index('redirect:').nil? sitemap.puts '' - sitemap.puts ' http://bitcoin.org/'+file1+'/'+file2.gsub('.html','')+'' + sitemap.puts ' https://bitcoin.org/'+file1+'/'+file2.gsub('.html','')+'' sitemap.puts '' end end @@ -85,14 +85,14 @@ def generate(site) data = File.read(file1) next if !data.index('window.location.href=').nil? or !data.index('redirect:').nil? or !data.index('google-site-verification:').nil? sitemap.puts '' - sitemap.puts ' http://bitcoin.org/'+file1.gsub('.html','')+'' + sitemap.puts ' https://bitcoin.org/'+file1.gsub('.html','')+'' sitemap.puts '' end #Add english alerts pages Dir.foreach('_alerts') do |file| next if file == '.' or file == '..' sitemap.puts '' - sitemap.puts ' http://bitcoin.org/en/alert/'+file.gsub('.html','')+'' + sitemap.puts ' https://bitcoin.org/en/alert/'+file.gsub('.html','')+'' sitemap.puts '' end #Add english releases pages @@ -105,7 +105,7 @@ def generate(site) file.shift() file = file.join('-') sitemap.puts '' - sitemap.puts ' http://bitcoin.org/en/release/'+file.gsub('.md','').gsub('.html','')+'' + sitemap.puts ' https://bitcoin.org/en/release/'+file.gsub('.md','').gsub('.html','')+'' sitemap.puts '' end #Close sitemap diff --git a/robots.txt b/robots.txt index 3fca3fef44..8ee2176541 100644 --- a/robots.txt +++ b/robots.txt @@ -1 +1 @@ -Sitemap: http://bitcoin.org/sitemap.xml +Sitemap: https://bitcoin.org/sitemap.xml