diff --git a/ChangeLog b/ChangeLog index 40d16dc9e..45d3664d8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,6 @@ YaCy: The Search Engine with the friendly whale -version 0.424svn +version 0.43svn * ADDED: additional Shutdownmethod to run YaCy as Windows Service (theli) * ADDED: possibility to import the crawling queue (theli) * UPDATED: German translations (NN, rramthun) @@ -11,7 +11,8 @@ version 0.424svn * FIXED: minor bug-fix in Cache for some rare URLs (borg-0300) * ADDED: The YaCy-Bookmarkssystem (allo) * UPDATED: New Searchstyle - * FIXED: notifier.gif works even when only DATA is writable + * FIXED: notifier.gif works even when only DATA is writable (allo) + * FIXED: Translations work with readonly htroot now. (allo) version 0.40 (8/21/2005): * The Server now provides the virtuel Header IS_ADMIN (Alexander Schier) diff --git a/htroot/Language_p.java b/htroot/Language_p.java index 81503574a..296a69da3 100644 --- a/htroot/Language_p.java +++ b/htroot/Language_p.java @@ -85,7 +85,9 @@ public class Language_p { } String htRootPath = env.getConfig("htRootPath", "htroot"); File sourceDir = new File(env.getRootPath(), htRootPath); - File destDir = new File(env.getRootPath(), htRootPath + "/locale/" + lang.substring(0, lang.length() - 4));// cut + File destDir = new File(env.getConfig("htLocalePath","DATA/HTDOCS/locale"), lang.substring(0, lang.length() - 4));// cut + // .lng + //File destDir = new File(env.getRootPath(), htRootPath + "/locale/" + lang.substring(0, lang.length() - 4));// cut // .lng File translationFile = new File(langPath, lang); diff --git a/source/de/anomic/http/httpdFileHandler.java b/source/de/anomic/http/httpdFileHandler.java index a4c328c0a..60c0b6319 100644 --- a/source/de/anomic/http/httpdFileHandler.java +++ b/source/de/anomic/http/httpdFileHandler.java @@ -200,7 +200,7 @@ public final class httpdFileHandler extends httpdAbstractHandler implements http // create htLocaleDefault, htLocalePath if (htDefaultPath == null) htDefaultPath = new File(switchboard.getRootPath(), switchboard.getConfig("htDefaultPath","htroot")); - if (htLocalePath == null) htLocalePath = new File(switchboard.getRootPath(), switchboard.getConfig("htLocalePath","htroot/locale")); + if (htLocalePath == null) htLocalePath = new File(switchboard.getConfig("htLocalePath","DATA/HTDOCS/locale")); //htLocaleSelection = switchboard.getConfig("htLocaleSelection","default"); } diff --git a/source/migration.java b/source/migration.java index 93a739092..bc181628f 100644 --- a/source/migration.java +++ b/source/migration.java @@ -141,6 +141,10 @@ public class migration { sb.setConfig("parseableMimeTypes.URLREDIRECTOR", value); sb.setConfig("parseableMimeTypes.ICAP", value); } + //Locales in DATA, because DATA must be writable, htroot not. + if(sb.getConfig("htLocalePath", "htroot/locale").equals("htroot/locale")){ + sb.setConfig("htLocalePath", "DATA/HTDOCS/locale"); + } } } diff --git a/source/yacy.java b/source/yacy.java index 2adcded86..24c3a87e8 100644 --- a/source/yacy.java +++ b/source/yacy.java @@ -308,7 +308,7 @@ public final class yacy { // create default notifier picture //TODO: Use templates instead of copying images ... - if (!((new File(htRootPath, "env/grafics/notifier.gif")).exists())) try { + if (!((new File(htDocsPath, "notifier.gif")).exists())) try { serverFileUtils.copy(new File(htRootPath, "env/grafics/empty.gif"), new File(htDocsPath, "notifier.gif")); } catch (IOException e) {} @@ -413,7 +413,7 @@ public final class yacy { try{ //seperate try, because we want this, even when the File "version2 does not exist. if(! currentRev.equals(sb.getConfig("svnRevision", "")) ){ //is this another version?! final File sourceDir = new File(sb.getConfig("htRootPath", "htroot")); - final File destDir = new File(sourceDir, "locale/"+lang); + final File destDir = new File(sb.getConfig("htLocalePath", "DATA/HTDOCS/locale"), lang); if(translator.translateFilesRecursive(sourceDir, destDir, new File("DATA/LOCALE/"+lang+".lng"), "html,template,inc", "locale")){ //translate it //write the new Versionnumber diff --git a/yacy.init b/yacy.init index 2ef1467ba..9b488d9d9 100644 --- a/yacy.init +++ b/yacy.init @@ -53,7 +53,7 @@ defaultFiles = index.html,default.html,search.html,console.html,control.html,wel # the must exist as sub-path to htLocalePath # the htLocaleSelection selects from the given locales, value=one-of- htDefaultPath=htroot -htLocalePath=htroot/locale +htLocalePath=DATA/HTROOT/locale htLocaleLang=default/English,de/Deutsch,fr/Français,nl/Nederlands,it/Italiano,es/Español,pt/Portugês,fi/Suomi,se/Svenska,dk/Dansk,gr/Eλληvικα htLocaleSelection=default