diff --git a/locale/Babelfish.lua b/locale/Babelfish.lua index 1bfd67d..0b6f803 100644 --- a/locale/Babelfish.lua +++ b/locale/Babelfish.lua @@ -40,8 +40,14 @@ local files = { "Options/Options.lua", } +--[[ + The Language your addon was originally written in +]] +local baseLocale = "enUS" + --[[ The supported Languages + -- DO NOT INCLUDE the base locale here! ]] local locale = { "deDE", @@ -94,10 +100,10 @@ for idx, lang in ipairs(locale) do end -- Write enUS file -local file = io.open("enUS.lua", "w") +local file = io.open(string.format("%s.lua", baseLocale), "w") assert(file, "Could not open enUS.lua for writing") file:write("-- Generated by Babelfish script, do not edit directly.\n") -file:write(string.format("local L = LibStub(\"AceLocale-3.0\"):NewLocale(\"%s\", \"enUS\", true)\n", localeName)) +file:write(string.format("local L = LibStub(\"AceLocale-3.0\"):NewLocale(\"%s\", \"%s\", true)\n", localeName, baseLocale)) file:write("\n\n") for idx, match in ipairs(work) do file:write(string.format("L[\"%s\"] = true\n", match))