From c2610b0df5dc6d7d60f3b2346ba4427175137881 Mon Sep 17 00:00:00 2001 From: wiidev Date: Mon, 11 Nov 2019 20:00:00 +0000 Subject: [PATCH] Download languages and updates from GitHub --- Languages/index.html | 32 ++++++++++++++++++++++++++++++ source/language/UpdateLanguage.cpp | 5 +++-- source/network/update.cpp | 13 ++++++------ 3 files changed, 41 insertions(+), 9 deletions(-) create mode 100644 Languages/index.html diff --git a/Languages/index.html b/Languages/index.html new file mode 100644 index 00000000..850dccde --- /dev/null +++ b/Languages/index.html @@ -0,0 +1,32 @@ + + + Languages + + + + + diff --git a/source/language/UpdateLanguage.cpp b/source/language/UpdateLanguage.cpp index b02798e1..b45f51d1 100644 --- a/source/language/UpdateLanguage.cpp +++ b/source/language/UpdateLanguage.cpp @@ -22,7 +22,8 @@ #include "gecko.h" #include "svnrev.h" -static const char * LanguageFilesURL = "https://svn.code.sf.net/p/usbloadergx/code/trunk/Languages/"; +static const char * LanguageFilesURL = "https://raw.githubusercontent.com/wiidev/usbloadergx/enhanced/Languages/"; +static const char * LanguagesURL = "https://raw.githubusercontent.com/wiidev/usbloadergx/enhanced/Languages/index.html"; int DownloadAllLanguageFiles(int revision) { @@ -39,7 +40,7 @@ int DownloadAllLanguageFiles(int revision) } char fullURL[300]; - URL_List LinkList(LanguageFilesURL); + URL_List LinkList(LanguagesURL); int listsize = LinkList.GetURLCount(); int files_downloaded = 0; char target[6]; diff --git a/source/network/update.cpp b/source/network/update.cpp index c73fb7c4..bf4cdb68 100644 --- a/source/network/update.cpp +++ b/source/network/update.cpp @@ -149,7 +149,7 @@ static void UpdateIconPng() { char iconpath[200]; struct download file = {}; - downloadfile("https://svn.code.sf.net/p/usbloadergx/code/branches/updates/icon.png", &file); + downloadfile("https://raw.githubusercontent.com/wiidev/usbloadergx/updates/icon.png", &file); if (file.size > 0) { snprintf(iconpath, sizeof(iconpath), "%sicon.png", Settings.update_path); @@ -167,8 +167,7 @@ static void UpdateMetaXml() { char xmlpath[200]; struct download file = {}; - downloadfile("https://svn.code.sf.net/p/usbloadergx/code/branches/updates/meta.xml", &file); - // if not working, use this url form: http://sourceforge.net/p/usbloadergx/code/1254/tree//branches/updates/meta.xml?format=raw + downloadfile("https://raw.githubusercontent.com/wiidev/usbloadergx/updates/meta.xml", &file); if (file.size > 0) { snprintf(xmlpath, sizeof(xmlpath), "%smeta.xml", Settings.update_path); @@ -192,9 +191,9 @@ int CheckUpdate() struct download file = {}; #ifdef FULLCHANNEL - downloadfile("https://svn.code.sf.net/p/usbloadergx/code/branches/updates/update_wad.txt", &file); + downloadfile("https://raw.githubusercontent.com/wiidev/usbloadergx/updates/update_wad.txt", &file); #else - downloadfile("https://svn.code.sf.net/p/usbloadergx/code/branches/updates/update_dol.txt", &file); + downloadfile("https://raw.githubusercontent.com/wiidev/usbloadergx/updates/update_dol.txt", &file); #endif if (file.size > 0) @@ -217,9 +216,9 @@ static int ApplicationDownload(void) struct download file = {}; #ifdef FULLCHANNEL - downloadfile("https://svn.code.sf.net/p/usbloadergx/code/branches/updates/update_wad.txt", &file); + downloadfile("https://raw.githubusercontent.com/wiidev/usbloadergx/updates/update_wad.txt", &file); #else - downloadfile("https://svn.code.sf.net/p/usbloadergx/code/branches/updates/update_dol.txt", &file); + downloadfile("https://raw.githubusercontent.com/wiidev/usbloadergx/updates/update_dol.txt", &file); #endif if (file.size > 0)