[LyX/2.3.x] Download dictionaries and thesauri from SVN.

Richard Kimberly Heck rikiheck at lyx.org
Sun Apr 5 18:29:56 UTC 2020


commit 1bd2e72d5a6d782e83eabc68051a4f6648e8004f
Author: Richard Kimberly Heck <rikiheck at lyx.org>
Date:   Sun Apr 5 14:48:19 2020 -0400

    Download dictionaries and thesauri from SVN.
    
    Patch from Eugene.
    
    (cherry picked from commit 36a1f365f00c8ae0a206dfef8fcef782faa5d454)
---
 .../packaging/installer/include/dictionaries.nsh   |   38 +++----------------
 status.23x                                         |    2 +
 2 files changed, 8 insertions(+), 32 deletions(-)

diff --git a/development/Win32/packaging/installer/include/dictionaries.nsh b/development/Win32/packaging/installer/include/dictionaries.nsh
index 4bec27e..8c995d5 100644
--- a/development/Win32/packaging/installer/include/dictionaries.nsh
+++ b/development/Win32/packaging/installer/include/dictionaries.nsh
@@ -73,22 +73,9 @@ Function DownloadHunspellDictionaries
   
   ${if} $DictCode == $R3
    StrCpy $String $String -2 # delete the linebreak characters at the end
-   # Download hunspell dictionaries,
-   # if first download repository is not available try the other ones listed in "DictionaryMirrors.txt"
-   FileOpen $R4 "$INSTDIR\Resources\DictionaryMirrors.txt" r
-   
-   ${For} $4 1 24 # there are 24 mirrors in the file
-    FileRead $R4 $Search # $Search is now the mirror
-    StrCpy $Search $Search -2 # delete the linebreak characters at the end
-    Push $R0
-    inetc::get /TIMEOUT=5000 "https://$Search.dl.sourceforge.net/project/lyxwininstaller/hunspell/$String" "$INSTDIR\Resources\dicts\$String" /END
-    Pop $R0
-    ${if} $R0 == "OK"
-     ${ExitFor}
-    ${endif}
-   ${Next}
-   
-   FileClose $R4
+   # Download hunspell dictionaries
+   inetc::get /TIMEOUT=5000 "https://www.lyx.org/trac/export/HEAD/lyxsvn/dictionaries/trunk/dicts/$String" "$INSTDIR\Resources\dicts\$String" /END
+   Pop $R0
    # if download failed
    ${if} $R0 != "OK"
     MessageBox MB_OK|MB_ICONEXCLAMATION "$(HunspellFailed)"
@@ -119,22 +106,9 @@ Function DownloadThesaurusDictionaries
   
   ${if} $ThesCode == $R3
    StrCpy $String $String -2 # delete the linebreak characters at the end
-   # Download thesaurus files,
-   # if first download repository is not available try the other ones listed in "DictionaryMirrors.txt"
-   FileOpen $R4 "$INSTDIR\Resources\DictionaryMirrors.txt" r
-   
-   ${For} $4 1 24 # there are 24 mirrors in the file
-    FileRead $R4 $Search # $Search is now the mirror
-    StrCpy $Search $Search -2 # delete the linebreak characters at the end
-    Push $R0
-    inetc::get /TIMEOUT=5000 "https://$Search.dl.sourceforge.net/project/lyxwininstaller/thesaurus/$String" "$INSTDIR\Resources\thes\$String" /END
-    Pop $R0
-    ${if} $R0 == "OK"
-     ${ExitFor}
-    ${endif}
-   ${Next}
-   
-   FileClose $R4
+   # Download thesaurus files
+   inetc::get /TIMEOUT=5000 "https://www.lyx.org/trac/export/HEAD/lyxsvn/dictionaries/trunk/thes/$String" "$INSTDIR\Resources\thes\$String" /END
+   Pop $R0
    # if download failed
    ${if} $R0 != "OK"
     MessageBox MB_OK|MB_ICONEXCLAMATION "$(ThesaurusFailed)"
diff --git a/status.23x b/status.23x
index 23d76af..3b68819 100644
--- a/status.23x
+++ b/status.23x
@@ -120,3 +120,5 @@ What's new
 - Do not break configuration if a layout file is not decodable. Rather than that, 
   issue a warning and skip that file (bug 11736).
 
+- Download dictionary and thesaurus files, on Windows, from our SVN repo (bug 11192).
+


More information about the lyx-cvs mailing list