From 865ee7674df3678be760e63fa4c80a15cbf11ebf Mon Sep 17 00:00:00 2001 From: falkTX Date: Sun, 31 Jan 2016 00:15:36 +0100 Subject: [PATCH] Handle both '+' and '~' url redirects for github downloads --- pool/free-v5/.htaccess | 9 ++++----- pool/free/.htaccess | 9 ++++----- pool/non-free-v5/.htaccess | 9 ++++----- pool/non-free/.htaccess | 9 ++++----- 4 files changed, 16 insertions(+), 20 deletions(-) diff --git a/pool/free-v5/.htaccess b/pool/free-v5/.htaccess index 226481c..a3a3a24 100644 --- a/pool/free-v5/.htaccess +++ b/pool/free-v5/.htaccess @@ -4,9 +4,8 @@ RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d -RewriteCond %{REQUEST_URI} !\+ -RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1 [R=301,L,QSA] - -RewriteCond %{REQUEST_FILENAME} !-f -RewriteCond %{REQUEST_FILENAME} !-d +RewriteCond %{REQUEST_URI} \+ RewriteRule ^(.*)\+(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1\.$2 [R=301,L,QSA] +RewriteCond %{REQUEST_URI} \~ +RewriteRule ^(.*)\~(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1\.$2 [R=301,L,QSA] +RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1 [R=301,L,QSA] diff --git a/pool/free/.htaccess b/pool/free/.htaccess index e29ab7c..330fbb0 100644 --- a/pool/free/.htaccess +++ b/pool/free/.htaccess @@ -4,9 +4,8 @@ RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d -RewriteCond %{REQUEST_URI} !\+ -RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1 [R=301,L,QSA] - -RewriteCond %{REQUEST_FILENAME} !-f -RewriteCond %{REQUEST_FILENAME} !-d +RewriteCond %{REQUEST_URI} \+ RewriteRule ^(.*)\+(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1\.$2 [R=301,L,QSA] +RewriteCond %{REQUEST_URI} \~ +RewriteRule ^(.*)\~(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1\.$2 [R=301,L,QSA] +RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1 [R=301,L,QSA] diff --git a/pool/non-free-v5/.htaccess b/pool/non-free-v5/.htaccess index 226481c..a3a3a24 100644 --- a/pool/non-free-v5/.htaccess +++ b/pool/non-free-v5/.htaccess @@ -4,9 +4,8 @@ RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d -RewriteCond %{REQUEST_URI} !\+ -RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1 [R=301,L,QSA] - -RewriteCond %{REQUEST_FILENAME} !-f -RewriteCond %{REQUEST_FILENAME} !-d +RewriteCond %{REQUEST_URI} \+ RewriteRule ^(.*)\+(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1\.$2 [R=301,L,QSA] +RewriteCond %{REQUEST_URI} \~ +RewriteRule ^(.*)\~(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1\.$2 [R=301,L,QSA] +RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/gcc5/$1 [R=301,L,QSA] diff --git a/pool/non-free/.htaccess b/pool/non-free/.htaccess index e29ab7c..330fbb0 100644 --- a/pool/non-free/.htaccess +++ b/pool/non-free/.htaccess @@ -4,9 +4,8 @@ RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d -RewriteCond %{REQUEST_URI} !\+ -RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1 [R=301,L,QSA] - -RewriteCond %{REQUEST_FILENAME} !-f -RewriteCond %{REQUEST_FILENAME} !-d +RewriteCond %{REQUEST_URI} \+ RewriteRule ^(.*)\+(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1\.$2 [R=301,L,QSA] +RewriteCond %{REQUEST_URI} \~ +RewriteRule ^(.*)\~(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1\.$2 [R=301,L,QSA] +RewriteRule ^(.*)$ https://github.com/KXStudio/Repository/releases/download/initial/$1 [R=301,L,QSA]