Module:User:Dixtosa/temporary

local export = {}

local lang = require("Module:languages").getByCode("ka") local strutils = require("Module:string utilities") local template = require("Module:User:Dixtosa/temporary/lua").template local getForms = require("Module:ka-infl-noun").getForms

function show fillCs for k, val in pairs(forms) do       forms[k] = mw.ustring.gsub(val, "%*", "") end return strutils.format(template, forms) end

local testterms = { {"*ი"}, {"*ა"}, {"*ე"}, {"*ო"}, {"*უ"},	{"*ორი", {"*ვრ"}}, {"*ოლი", {"*ლ"}}, {"*ობი", {"*ბ"}}, {"*ორი", {"*რ"}}, {"*ანა", {"*ნ"}}, {"*აბი", {"*ბ"}}, {"*ადი", {"*დ"}}, {"*ავი", {"*ვ"}}, {"*არი", {"*რ"}}, {"*არე", {"*რ"}}, {"*ალი", {"*ლ"}}, {"*არა", {"*რ"}}, {"*ანი", {"*ნ"}}, {"*ამი", {"*მ"}}, {"*ელა", {"*ლ"}}, {"*ელი", {"*ლ"}}, {"*ერი", {"*რ"}}, {"*ენი", {"*ნ"}}, {"*ემი", {"*მ"}}, {"*ეხი", {"*ხ"}}, {"*ედი", {"*დ"}} }

function export.main local res = "" for _, testterm in pairs(testterms) do		local term = testterm[1] local args = testterm[2] or {} res = res .. show({term = term, args = args}) end return res end

--კაცისთვისა postpRuleAboutA = { "vit", "tan", "tvis", "ken", "gan", "dan" }

postpRuleAboutC = { ["vit"] = "აც", ["ze"] = "ც", ["tan"] = "აც", ["shi"] = "ც",

["tvis"] = "აც", ["ebr" ] = nil, ["ken" ] = "აც", ["gan" ] = "აც",

["dan" ] = "აც", ["urt" ] = nil,

["mde" ] = "ც" }

function fillCs forms["nom1_c_a"] = forms["c_nom1"] and forms["c_nom1"] .. "ცა" local cases = {"nom1", "erg1", "dat1a", "gen1a", "ins1a", "adv1a", "nom2", "erg2", "dat2a", "gen2a", "ins2a", "adv2a"} for k, case in pairs(cases) do		if forms[k] ~= "" then forms[k .. "_c"] = case .. "ც" end end

for postcase, suffix in pairs(postpRuleAboutA) do		if forms[postcase] and suffix then forms[postcase .. "_c"] = forms[postcase] .. suffix end if forms[postcase.."_pl"] and suffix then forms[postcase .. "_pl_c"] = forms[postcase .. "_pl"] .. suffix end end for _, case in pairs(postpRuleAboutA) do		if forms[postcase] then forms[postcase .. "_a"] = forms[postcase] .. "ა" end if forms[postcase.."_pl"] then forms[postcase .. "_pl_a"] = forms[postcase .. "_pl"] .. "ა" end end end

return export