From fd3b81e7c04b032ce36a18ae00ce8cf95ffd649f Mon Sep 17 00:00:00 2001 From: MasterEnoc Date: Sun, 15 Nov 2020 18:34:25 -0600 Subject: [PATCH 1/3] Update Gcc scraper - Add 10.2.0 version - Update previous versions --- docs/file-scrapers.md | 18 ++++++++++++++++++ lib/docs/scrapers/gnu/gcc.rb | 34 ++++++++++++++++++++++------------ 2 files changed, 40 insertions(+), 12 deletions(-) diff --git a/docs/file-scrapers.md b/docs/file-scrapers.md index 506e9a59..a225e4c3 100644 --- a/docs/file-scrapers.md +++ b/docs/file-scrapers.md @@ -35,6 +35,24 @@ Go to https://www.erlang.org/downloads and download the HTML documentation file. ## Gnu ### GCC +Go to https://gcc.gnu.org/onlinedocs/ and download the HTML tarball of GCC Manual and GCC CPP manual or run the following commands to download the tarballs: + +```sh +# Gcc manual +wget https://gcc.gnu.org/onlinedocs/gcc-/gcc-html.tar.gz +# Gcc cpp manual +wget https://gcc.gnu.org/onlinedocs/gcc-/cpp-html.tar.gz +``` + +Then extract the content of the tarball and move it to the devdocs directory. + +```sh +tar xf +# Gcc +mv path/to/devdocs/docs/gcc~/ +# Gcc Cpp +mv path/to/devdocs/docs/gcc~_cpp/ +``` ### GNU Fortran ## Gnuplot diff --git a/lib/docs/scrapers/gnu/gcc.rb b/lib/docs/scrapers/gnu/gcc.rb index 9cfcf6a3..21e88872 100644 --- a/lib/docs/scrapers/gnu/gcc.rb +++ b/lib/docs/scrapers/gnu/gcc.rb @@ -46,79 +46,89 @@ module Docs 'Wtrigraphs.html' => 'Invocation.html' } + version '10' do + self.release = '10.2.0' + self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" + end + + version '10 CPP' do + self.release = '10.2.0' + self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" + end + version '9' do - self.release = '9.2.0' + self.release = '9.3.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" end version '9 CPP' do - self.release = '9.2.0' + self.release = '9.3.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '8' do - self.release = '8.3.0' + self.release = '8.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" end version '8 CPP' do - self.release = '8.3.0' + self.release = '8.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '7' do - self.release = '7.4.0' + self.release = '7.5.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" end version '7 CPP' do - self.release = '7.4.0' + self.release = '7.5.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '6' do - self.release = '6.4.0' + self.release = '6.5.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" options[:root_title] = 'Using the GNU Compiler Collection (GCC)' end version '6 CPP' do - self.release = '6.4.0' + self.release = '6.5.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '5' do - self.release = '5.4.0' + self.release = '5.5.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" options[:root_title] = 'Using the GNU Compiler Collection (GCC)' end version '5 CPP' do - self.release = '5.4.0' + self.release = '5.5.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '4' do - self.release = '4.9.3' + self.release = '4.9.4' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" options[:root_title] = 'Using the GNU Compiler Collection (GCC)' end version '4 CPP' do - self.release = '4.9.3' + self.release = '4.9.4' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS From 96fb77b52d9972fc9e760daff54feef8325e36fc Mon Sep 17 00:00:00 2001 From: MasterEnoc Date: Tue, 17 Nov 2020 19:01:59 -0600 Subject: [PATCH 2/3] Undo the changes in older versions of gcc --- lib/docs/scrapers/gnu/gcc.rb | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/lib/docs/scrapers/gnu/gcc.rb b/lib/docs/scrapers/gnu/gcc.rb index 21e88872..6b4f3815 100644 --- a/lib/docs/scrapers/gnu/gcc.rb +++ b/lib/docs/scrapers/gnu/gcc.rb @@ -69,66 +69,66 @@ module Docs end version '8' do - self.release = '8.4.0' + self.release = '8.3.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" end version '8 CPP' do - self.release = '8.4.0' + self.release = '8.3.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '7' do - self.release = '7.5.0' + self.release = '7.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" end version '7 CPP' do - self.release = '7.5.0' + self.release = '7.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '6' do - self.release = '6.5.0' + self.release = '6.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" options[:root_title] = 'Using the GNU Compiler Collection (GCC)' end version '6 CPP' do - self.release = '6.5.0' + self.release = '6.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '5' do - self.release = '5.5.0' + self.release = '5.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" options[:root_title] = 'Using the GNU Compiler Collection (GCC)' end version '5 CPP' do - self.release = '5.5.0' + self.release = '5.4.0' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS end version '4' do - self.release = '4.9.4' + self.release = '4.9.3' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/gcc/" options[:root_title] = 'Using the GNU Compiler Collection (GCC)' end version '4 CPP' do - self.release = '4.9.4' + self.release = '4.9.3' self.base_url = "https://gcc.gnu.org/onlinedocs/gcc-#{release}/cpp/" options[:replace_paths] = CPP_PATHS From d76be6b7b07e0fae48f3c78fa08a457d90b7b793 Mon Sep 17 00:00:00 2001 From: Simon Legner Date: Wed, 18 Nov 2020 20:44:32 +0100 Subject: [PATCH 3/3] gcc: update docs/file-scrapers.md --- docs/file-scrapers.md | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/docs/file-scrapers.md b/docs/file-scrapers.md index a225e4c3..cf91c61e 100644 --- a/docs/file-scrapers.md +++ b/docs/file-scrapers.md @@ -38,21 +38,17 @@ Go to https://www.erlang.org/downloads and download the HTML documentation file. Go to https://gcc.gnu.org/onlinedocs/ and download the HTML tarball of GCC Manual and GCC CPP manual or run the following commands to download the tarballs: ```sh -# Gcc manual -wget https://gcc.gnu.org/onlinedocs/gcc-/gcc-html.tar.gz -# Gcc cpp manual -wget https://gcc.gnu.org/onlinedocs/gcc-/cpp-html.tar.gz +# GCC manual +mkdir docs/gcc~${VERSION}; \ +curl https://gcc.gnu.org/onlinedocs/gcc-$RELEASE/gcc-html.tar.gz | \ +tar --extract --gzip --strip-components=1 --directory=docs/gcc~${VERSION} + +# GCC CPP manual +mkdir docs/gcc~${VERSION}_cpp; \ +curl https://gcc.gnu.org/onlinedocs/gcc-$RELEASE/cpp-html.tar.gz | \ +tar --extract --gzip --strip-components=1 --directory=docs/gcc~${VERSION}_cpp ``` -Then extract the content of the tarball and move it to the devdocs directory. - -```sh -tar xf -# Gcc -mv path/to/devdocs/docs/gcc~/ -# Gcc Cpp -mv path/to/devdocs/docs/gcc~_cpp/ -``` ### GNU Fortran ## Gnuplot