From 9ba1ea463eb0ba5d9075963bd654364014473646 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 19 Mar 2018 00:41:05 +0000 Subject: [PATCH 01/20] README: clarify modpython requirements --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b50d539f..857a8c9d 100644 --- a/README.md +++ b/README.md @@ -43,8 +43,8 @@ modperl: * SWIG if building from git modpython: -* python and its bundled libpython -* perl is required +* python3 and its bundled libpython +* perl is a build dependency * macOS: Python from Homebrew is preferred over system version * SWIG if building from git From ece09d11b59c88f40e374d0a1a5723a368c37700 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 19 Mar 2018 00:45:46 +0000 Subject: [PATCH 02/20] README: recommend out of tree build --- README.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 857a8c9d..1646ccbd 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,9 @@ but calls CMake with CMake-style parameters. Installation from source code is performed using the CMake toolchain. ```shell -cmake . +mkdir build +cd build +cmake .. make make install ``` @@ -87,7 +89,9 @@ If you are building from git, you will need to run `./autogen.sh` first to produce the `configure` script. ```shell -./configure +mkdir build +cd build +../configure make make install ``` From 2e31a8ee9734854f3c82409af77cdc6c29239974 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 19 Mar 2018 00:41:28 +0000 Subject: [PATCH 03/20] README: mention i18n --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 1646ccbd..6ab52284 100644 --- a/README.md +++ b/README.md @@ -54,6 +54,11 @@ cyrusauth: Character Encodings: * To get proper character encoding and charsets install ICU (`libicu4-dev`) +I18N (UI translation) +* CMake-based build only +* Boost.Locale +* gettext is a build dependency + ## Installing ZNC Currently there are 2 build systems in place: CMake and `./configure`. From 6ca2d5caa04ddcec045b91f1a90d52424351d409 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Sun, 25 Mar 2018 22:57:05 +0100 Subject: [PATCH 04/20] More translateable strings, #1354 --- include/znc/Chan.h | 3 +- src/Chan.cpp | 4 +- src/ClientCommand.cpp | 794 +++++++++++++++++++++--------------------- 3 files changed, 408 insertions(+), 393 deletions(-) diff --git a/include/znc/Chan.h b/include/znc/Chan.h index 699a740d..47bc21d8 100644 --- a/include/znc/Chan.h +++ b/include/znc/Chan.h @@ -21,6 +21,7 @@ #include #include #include +#include #include // Forward Declarations @@ -31,7 +32,7 @@ class CConfig; class CFile; // !Forward Declarations -class CChan { +class CChan : private CCoreTranslationMixin { public: typedef enum { Voice = '+', diff --git a/src/Chan.cpp b/src/Chan.cpp index aae7e7f6..1d6a0791 100644 --- a/src/Chan.cpp +++ b/src/Chan.cpp @@ -635,7 +635,7 @@ void CChan::SendBuffer(CClient* pClient, const CBuffer& Buffer) { if (!bSkipStatusMsg) { m_pNetwork->PutUser(":***!znc@znc.in PRIVMSG " + GetName() + - " :Buffer Playback...", + " :" + t_s("Buffer Playback..."), pUseClient); } @@ -673,7 +673,7 @@ void CChan::SendBuffer(CClient* pClient, const CBuffer& Buffer) { &bSkipStatusMsg); if (!bSkipStatusMsg) { m_pNetwork->PutUser(":***!znc@znc.in PRIVMSG " + GetName() + - " :Playback Complete.", + " :" + t_s("Playback Complete."), pUseClient); } diff --git a/src/ClientCommand.cpp b/src/ClientCommand.cpp index 63be0ea5..5c9d6384 100644 --- a/src/ClientCommand.cpp +++ b/src/ClientCommand.cpp @@ -88,9 +88,9 @@ void CClient::UserCommand(CString& sLine) { Table.AddColumn(sPerm); } - Table.AddColumn("Nick"); - Table.AddColumn("Ident"); - Table.AddColumn("Host"); + Table.AddColumn(t_s("Nick")); + Table.AddColumn(t_s("Ident")); + Table.AddColumn(t_s("Host")); for (const auto& it : msNicks) { Table.AddRow(); @@ -103,72 +103,76 @@ void CClient::UserCommand(CString& sLine) { } } - Table.SetCell("Nick", it.second.GetNick()); - Table.SetCell("Ident", it.second.GetIdent()); - Table.SetCell("Host", it.second.GetHost()); + Table.SetCell(t_s("Nick"), it.second.GetNick()); + Table.SetCell(t_s("Ident"), it.second.GetIdent()); + Table.SetCell(t_s("Host"), it.second.GetHost()); } PutStatus(Table); } else if (sCommand.Equals("ATTACH")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sPatterns = sLine.Token(1, true); if (sPatterns.empty()) { - PutStatus("Usage: Attach <#chans>"); + PutStatus(t_s("Usage: Attach <#chans>")); return; } set sChans = MatchChans(sPatterns); unsigned int uAttachedChans = AttachChans(sChans); - PutStatus("There were [" + CString(sChans.size()) + - "] channels matching [" + sPatterns + "]"); - PutStatus("Attached [" + CString(uAttachedChans) + "] channels"); + PutStatus(t_p("There was {1} channel matching [{2}]", + "There were {1} channels matching [{2}]", + sChans.size())(sChans.size(), sPatterns)); + PutStatus(t_p("Attached {1} channel", "Attached {2} channels", + uAttachedChans)(uAttachedChans)); } else if (sCommand.Equals("DETACH")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sPatterns = sLine.Token(1, true); if (sPatterns.empty()) { - PutStatus("Usage: Detach <#chans>"); + PutStatus(t_s("Usage: Detach <#chans>")); return; } set sChans = MatchChans(sPatterns); unsigned int uDetached = DetachChans(sChans); - PutStatus("There were [" + CString(sChans.size()) + - "] channels matching [" + sPatterns + "]"); - PutStatus("Detached [" + CString(uDetached) + "] channels"); + PutStatus(t_p("There was {1} channel matching [{2}]", + "There were {1} channels matching [{2}]", + sChans.size())(sChans.size(), sPatterns)); + PutStatus(t_p("Detached {1} channel", "Detached {2} channels", + uDetached)(uDetached)); } else if (sCommand.Equals("VERSION")) { PutStatus(CZNC::GetTag()); PutStatus(CZNC::GetCompileOptionsString()); } else if (sCommand.Equals("MOTD") || sCommand.Equals("ShowMOTD")) { if (!SendMotd()) { - PutStatus("There is no MOTD set."); + PutStatus(t_s("There is no MOTD set.")); } } else if (m_pUser->IsAdmin() && sCommand.Equals("Rehash")) { CString sRet; if (CZNC::Get().RehashConfig(sRet)) { - PutStatus("Rehashing succeeded!"); + PutStatus(t_s("Rehashing succeeded!")); } else { - PutStatus("Rehashing failed: " + sRet); + PutStatus(t_f("Rehashing failed: {1}")(sRet)); } } else if (m_pUser->IsAdmin() && sCommand.Equals("SaveConfig")) { if (CZNC::Get().WriteConfig()) { - PutStatus("Wrote config to [" + CZNC::Get().GetConfigFile() + "]"); + PutStatus(t_f("Wrote config to {1}")(CZNC::Get().GetConfigFile())); } else { - PutStatus("Error while trying to write config."); + PutStatus(t_s("Error while trying to write config.")); } } else if (sCommand.Equals("LISTCLIENTS")) { CUser* pUser = m_pUser; @@ -443,25 +447,26 @@ void CClient::UserCommand(CString& sLine) { CIRCNetwork* pNetwork = m_pNetwork; - const CString sNick = sLine.Token(1); + const CString sUser = sLine.Token(1); const CString sNetwork = sLine.Token(2); - if (!sNick.empty()) { + if (!sUser.empty()) { if (!m_pUser->IsAdmin()) { - PutStatus("Usage: ListChans"); + PutStatus(t_s("Usage: ListChans")); return; } - CUser* pUser = CZNC::Get().FindUser(sNick); + CUser* pUser = CZNC::Get().FindUser(sUser); if (!pUser) { - PutStatus("No such user [" + sNick + "]"); + PutStatus(t_f("No such user [{1}]")(sUser)); return; } pNetwork = pUser->FindNetwork(sNetwork); if (!pNetwork) { - PutStatus("No such network for user [" + sNetwork + "]"); + PutStatus(t_f("User [{1}] doesn't have network [{2}]")( + sUser, sNetwork)); return; } } @@ -471,18 +476,18 @@ void CClient::UserCommand(CString& sLine) { CString sPerms = pIRCSock ? pIRCSock->GetPerms() : ""; if (vChans.empty()) { - PutStatus("There are no channels defined."); + PutStatus(t_s("There are no channels defined.")); return; } CTable Table; - Table.AddColumn("Name"); - Table.AddColumn("Status"); - Table.AddColumn("Conf"); - Table.AddColumn("Buf"); - Table.AddColumn("Clear"); - Table.AddColumn("Modes"); - Table.AddColumn("Users"); + Table.AddColumn(t_s("Name", "listchans")); + Table.AddColumn(t_s("Status", "listchans")); + Table.AddColumn(t_s("In config", "listchans")); + Table.AddColumn(t_s("Buffer", "listchans")); + Table.AddColumn(t_s("Clear", "listchans")); + Table.AddColumn(t_s("Modes", "listchans")); + Table.AddColumn(t_s("Users", "listchans")); for (char cPerm : sPerms) { Table.AddColumn(CString(cPerm)); @@ -492,21 +497,30 @@ void CClient::UserCommand(CString& sLine) { for (const CChan* pChan : vChans) { Table.AddRow(); - Table.SetCell("Name", pChan->GetPermStr() + pChan->GetName()); - Table.SetCell("Status", - pChan->IsOn() - ? (pChan->IsDetached() ? "Detached" : "Joined") - : (pChan->IsDisabled() ? "Disabled" : "Trying")); - Table.SetCell("Conf", CString(pChan->InConfig() ? "yes" : "")); - Table.SetCell("Buf", + Table.SetCell(t_s("Name", "listchans"), + pChan->GetPermStr() + pChan->GetName()); + Table.SetCell( + t_s("Status", "listchans"), + pChan->IsOn() + ? (pChan->IsDetached() ? t_s("Detached", "listchans") + : t_s("Joined", "listchans")) + : (pChan->IsDisabled() ? t_s("Disabled", "listchans") + : t_s("Trying", "listchans"))); + Table.SetCell( + t_s("In config", "listchans"), + CString(pChan->InConfig() ? t_s("yes", "listchans") : "")); + Table.SetCell(t_s("Buffer", "listchans"), CString(pChan->HasBufferCountSet() ? "*" : "") + CString(pChan->GetBufferCount())); Table.SetCell( - "Clear", + t_s("Clear", "listchans"), CString(pChan->HasAutoClearChanBufferSet() ? "*" : "") + - CString(pChan->AutoClearChanBuffer() ? "yes" : "")); - Table.SetCell("Modes", pChan->GetModeString()); - Table.SetCell("Users", CString(pChan->GetNickCount())); + CString(pChan->AutoClearChanBuffer() + ? t_s("yes", "listchans") + : "")); + Table.SetCell(t_s("Modes", "listchans"), pChan->GetModeString()); + Table.SetCell(t_s("Users", "listchans"), + CString(pChan->GetNickCount())); std::map mPerms = pChan->GetPermCounts(); for (char cPerm : sPerms) { @@ -519,46 +533,44 @@ void CClient::UserCommand(CString& sLine) { } PutStatus(Table); - PutStatus("Total: " + CString(vChans.size()) + " - Joined: " + - CString(uNumJoined) + " - Detached: " + - CString(uNumDetached) + " - Disabled: " + - CString(uNumDisabled)); + PutStatus(t_f("Total: {1}, Joined: {2}, Detached: {3}, Disabled: {4}")( + vChans.size(), uNumJoined, uNumDetached, uNumDisabled)); } else if (sCommand.Equals("ADDNETWORK")) { if (!m_pUser->IsAdmin() && !m_pUser->HasSpaceForNewNetwork()) { - PutStatus( + PutStatus(t_s( "Network number limit reached. Ask an admin to increase the " "limit for you, or delete unneeded networks using /znc " - "DelNetwork "); + "DelNetwork ")); return; } CString sNetwork = sLine.Token(1); if (sNetwork.empty()) { - PutStatus("Usage: AddNetwork "); + PutStatus(t_s("Usage: AddNetwork ")); return; } if (!CIRCNetwork::IsValidNetwork(sNetwork)) { - PutStatus("Network name should be alphanumeric"); + PutStatus(t_s("Network name should be alphanumeric")); return; } CString sNetworkAddError; if (m_pUser->AddNetwork(sNetwork, sNetworkAddError)) { - PutStatus("Network added. Use /znc JumpNetwork " + sNetwork + - ", or connect to ZNC with username " + - m_pUser->GetUserName() + "/" + sNetwork + - " (instead of just " + m_pUser->GetUserName() + - ") to connect to it."); + PutStatus( + t_f("Network added. Use /znc JumpNetwork {1}, or connect to " + "ZNC with username {2} (instead of just {3}) to connect to " + "it.")(sNetwork, m_pUser->GetUserName() + "/" + sNetwork, + m_pUser->GetUserName())); } else { - PutStatus("Unable to add that network"); + PutStatus(t_s("Unable to add that network")); PutStatus(sNetworkAddError); } } else if (sCommand.Equals("DELNETWORK")) { CString sNetwork = sLine.Token(1); if (sNetwork.empty()) { - PutStatus("Usage: DelNetwork "); + PutStatus(t_s("Usage: DelNetwork ")); return; } @@ -567,10 +579,11 @@ void CClient::UserCommand(CString& sLine) { } if (m_pUser->DeleteNetwork(sNetwork)) { - PutStatus("Network deleted"); + PutStatus(t_s("Network deleted")); } else { - PutStatus("Failed to delete network"); - PutStatus("Perhaps this network doesn't exist"); + PutStatus( + t_s("Failed to delete network, perhaps this network doesn't " + "exist")); } } else if (sCommand.Equals("LISTNETWORKS")) { CUser* pUser = m_pUser; @@ -579,7 +592,7 @@ void CClient::UserCommand(CString& sLine) { pUser = CZNC::Get().FindUser(sLine.Token(1)); if (!pUser) { - PutStatus("User not found " + sLine.Token(1)); + PutStatus(t_f("User {1} not found")(sLine.Token(1))); return; } } @@ -587,31 +600,36 @@ void CClient::UserCommand(CString& sLine) { const vector& vNetworks = pUser->GetNetworks(); CTable Table; - Table.AddColumn("Network"); - Table.AddColumn("OnIRC"); - Table.AddColumn("IRC Server"); - Table.AddColumn("IRC User"); - Table.AddColumn("Channels"); + Table.AddColumn(t_s("Network", "listnetworks")); + Table.AddColumn(t_s("On IRC", "listnetworks")); + Table.AddColumn(t_s("IRC Server", "listnetworks")); + Table.AddColumn(t_s("IRC User", "listnetworks")); + Table.AddColumn(t_s("Channels", "listnetworks")); for (const CIRCNetwork* pNetwork : vNetworks) { Table.AddRow(); - Table.SetCell("Network", pNetwork->GetName()); + Table.SetCell(t_s("Network", "listnetworks"), pNetwork->GetName()); if (pNetwork->IsIRCConnected()) { - Table.SetCell("OnIRC", "Yes"); - Table.SetCell("IRC Server", pNetwork->GetIRCServer()); - Table.SetCell("IRC User", pNetwork->GetIRCNick().GetNickMask()); - Table.SetCell("Channels", CString(pNetwork->GetChans().size())); + Table.SetCell(t_s("On IRC", "listnetworks"), + t_s("Yes", "listnetworks")); + Table.SetCell(t_s("IRC Server", "listnetworks"), + pNetwork->GetIRCServer()); + Table.SetCell(t_s("IRC User", "listnetworks"), + pNetwork->GetIRCNick().GetNickMask()); + Table.SetCell(t_s("Channels", "listnetworks"), + CString(pNetwork->GetChans().size())); } else { - Table.SetCell("OnIRC", "No"); + Table.SetCell(t_s("On IRC", "listnetworks"), + t_s("No", "listnetworks")); } } if (PutStatus(Table) == 0) { - PutStatus("No networks"); + PutStatus(t_s("No networks", "listnetworks")); } } else if (sCommand.Equals("MOVENETWORK")) { if (!m_pUser->IsAdmin()) { - PutStatus("Access Denied."); + PutStatus(t_s("Access denied.")); return; } @@ -621,9 +639,9 @@ void CClient::UserCommand(CString& sLine) { CString sNewNetwork = sLine.Token(4); if (sOldUser.empty() || sOldNetwork.empty() || sNewUser.empty()) { - PutStatus( + PutStatus(t_s( "Usage: MoveNetwork [new " - "network]"); + "network]")); return; } if (sNewNetwork.empty()) { @@ -632,30 +650,30 @@ void CClient::UserCommand(CString& sLine) { CUser* pOldUser = CZNC::Get().FindUser(sOldUser); if (!pOldUser) { - PutStatus("Old user [" + sOldUser + "] not found."); + PutStatus(t_f("Old user {1} not found.")(sOldUser)); return; } CIRCNetwork* pOldNetwork = pOldUser->FindNetwork(sOldNetwork); if (!pOldNetwork) { - PutStatus("Old network [" + sOldNetwork + "] not found."); + PutStatus(t_f("Old network {1} not found.")(sOldNetwork)); return; } CUser* pNewUser = CZNC::Get().FindUser(sNewUser); if (!pNewUser) { - PutStatus("New user [" + sOldUser + "] not found."); + PutStatus(t_f("New user {1} not found.")(sNewUser)); return; } if (pNewUser->FindNetwork(sNewNetwork)) { - PutStatus("User [" + sNewUser + "] already has network [" + - sNewNetwork + "]."); + PutStatus(t_f("User {1} already has network {2}.")(sNewUser, + sNewNetwork)); return; } if (!CIRCNetwork::IsValidNetwork(sNewNetwork)) { - PutStatus("Invalid network name [" + sNewNetwork + "]"); + PutStatus(t_f("Invalid network name [{1}]")(sNewNetwork)); return; } @@ -670,9 +688,9 @@ void CClient::UserCommand(CString& sLine) { CDir oldDir(sOldModPath); for (CFile* pFile : oldDir) { if (pFile->GetShortName() != ".registry") { - PutStatus("Some files seem to be in [" + sOldModPath + - "]. You might want to move them to [" + - sNewModPath + "]"); + PutStatus( + t_f("Some files seem to be in {1}. You might want to " + "move them to {2}")(sOldModPath, sNewModPath)); break; } } @@ -685,7 +703,7 @@ void CClient::UserCommand(CString& sLine) { pNewUser->AddNetwork(sNewNetwork, sNetworkAddError); if (!pNewNetwork) { - PutStatus("Error adding network:" + sNetworkAddError); + PutStatus(t_f("Error adding network: {1}")(sNetworkAddError)); return; } @@ -697,57 +715,57 @@ void CClient::UserCommand(CString& sLine) { } if (pOldUser->DeleteNetwork(sOldNetwork)) { - PutStatus("Success."); + PutStatus(t_s("Success.")); } else { PutStatus( - "Copied the network to new user, but failed to delete old " - "network"); + t_s("Copied the network to new user, but failed to delete old " + "network")); } } else if (sCommand.Equals("JUMPNETWORK")) { CString sNetwork = sLine.Token(1); if (sNetwork.empty()) { - PutStatus("No network supplied."); + PutStatus(t_s("No network supplied.")); return; } if (m_pNetwork && (m_pNetwork->GetName() == sNetwork)) { - PutStatus("You are already connected with this network."); + PutStatus(t_s("You are already connected with this network.")); return; } CIRCNetwork* pNetwork = m_pUser->FindNetwork(sNetwork); if (pNetwork) { - PutStatus("Switched to " + sNetwork); + PutStatus(t_f("Switched to {1}")(sNetwork)); SetNetwork(pNetwork); } else { - PutStatus("You don't have a network named " + sNetwork); + PutStatus(t_f("You don't have a network named {1}")(sNetwork)); } } else if (sCommand.Equals("ADDSERVER")) { CString sServer = sLine.Token(1); if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } if (sServer.empty()) { - PutStatus("Usage: AddServer [[+]port] [pass]"); + PutStatus(t_s("Usage: AddServer [[+]port] [pass]")); return; } if (m_pNetwork->AddServer(sLine.Token(1, true))) { - PutStatus("Server added"); + PutStatus(t_s("Server added")); } else { - PutStatus("Unable to add that server"); PutStatus( - "Perhaps the server is already added or openssl is disabled?"); + t_s("Unable to add that server. Perhaps the server is already " + "added or openssl is disabled?")); } } else if (sCommand.Equals("REMSERVER") || sCommand.Equals("DELSERVER")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } @@ -756,24 +774,24 @@ void CClient::UserCommand(CString& sLine) { CString sPass = sLine.Token(3); if (sServer.empty()) { - PutStatus("Usage: DelServer [port] [pass]"); + PutStatus(t_s("Usage: DelServer [port] [pass]")); return; } if (!m_pNetwork->HasServers()) { - PutStatus("You don't have any servers added."); + PutStatus(t_s("You don't have any servers added.")); return; } if (m_pNetwork->DelServer(sServer, uPort, sPass)) { - PutStatus("Server removed"); + PutStatus(t_s("Server removed")); } else { - PutStatus("No such server"); + PutStatus(t_s("No such server")); } } else if (sCommand.Equals("LISTSERVERS")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } @@ -781,59 +799,63 @@ void CClient::UserCommand(CString& sLine) { const vector& vServers = m_pNetwork->GetServers(); CServer* pCurServ = m_pNetwork->GetCurrentServer(); CTable Table; - Table.AddColumn("Host"); - Table.AddColumn("Port"); - Table.AddColumn("SSL"); - Table.AddColumn("Pass"); + Table.AddColumn(t_s("Host", "listservers")); + Table.AddColumn(t_s("Port", "listservers")); + Table.AddColumn(t_s("SSL", "listservers")); + Table.AddColumn(t_s("Password", "listservers")); for (const CServer* pServer : vServers) { Table.AddRow(); - Table.SetCell("Host", pServer->GetName() + + Table.SetCell(t_s("Host", "listservers"), pServer->GetName() + (pServer == pCurServ ? "*" : "")); - Table.SetCell("Port", CString(pServer->GetPort())); - Table.SetCell("SSL", (pServer->IsSSL()) ? "SSL" : ""); - Table.SetCell("Pass", (!pServer->GetPass().empty()) ? "set" : ""); + Table.SetCell(t_s("Port", "listservers"), + CString(pServer->GetPort())); + Table.SetCell( + t_s("SSL", "listservers"), + (pServer->IsSSL()) ? t_s("SSL", "listservers|cell") : ""); + Table.SetCell(t_s("Password", "listservers"), + pServer->GetPass().empty() ? "" : "******"); } PutStatus(Table); } else { - PutStatus("You don't have any servers added."); + PutStatus(t_s("You don't have any servers added.")); } } else if (sCommand.Equals("AddTrustedServerFingerprint")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sFP = sLine.Token(1); if (sFP.empty()) { - PutStatus("Usage: AddTrustedServerFingerprint "); + PutStatus(t_s("Usage: AddTrustedServerFingerprint ")); return; } m_pNetwork->AddTrustedFingerprint(sFP); - PutStatus("Done."); + PutStatus(t_s("Done.")); } else if (sCommand.Equals("DelTrustedServerFingerprint")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sFP = sLine.Token(1); if (sFP.empty()) { - PutStatus("Usage: DelTrustedServerFingerprint "); + PutStatus(t_s("Usage: DelTrustedServerFingerprint ")); return; } m_pNetwork->DelTrustedFingerprint(sFP); - PutStatus("Done."); + PutStatus(t_s("Done.")); } else if (sCommand.Equals("ListTrustedServerFingerprints")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } const SCString& ssFPs = m_pNetwork->GetTrustedFingerprints(); if (ssFPs.empty()) { - PutStatus("No fingerprints added."); + PutStatus(t_s("No fingerprints added.")); } else { int k = 0; for (const CString& sFP : ssFPs) { @@ -842,83 +864,64 @@ void CClient::UserCommand(CString& sLine) { } } else if (sCommand.Equals("TOPICS")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } const vector& vChans = m_pNetwork->GetChans(); CTable Table; - Table.AddColumn("Name"); - Table.AddColumn("Set By"); - Table.AddColumn("Topic"); + Table.AddColumn(t_s("Channel", "topicscmd")); + Table.AddColumn(t_s("Set By", "topicscmd")); + Table.AddColumn(t_s("Topic", "topicscmd")); for (const CChan* pChan : vChans) { Table.AddRow(); - Table.SetCell("Name", pChan->GetName()); - Table.SetCell("Set By", pChan->GetTopicOwner()); - Table.SetCell("Topic", pChan->GetTopic()); + Table.SetCell(t_s("Channel", "topicscmd"), pChan->GetName()); + Table.SetCell(t_s("Set By", "topicscmd"), pChan->GetTopicOwner()); + Table.SetCell(t_s("Topic", "topicscmd"), pChan->GetTopic()); } PutStatus(Table); } else if (sCommand.Equals("LISTMODS") || sCommand.Equals("LISTMODULES")) { + const auto PrintModules = [this](const CModules& Modules) { + CTable Table; + Table.AddColumn(t_s("Name", "listmods")); + Table.AddColumn(t_s("Arguments", "listmods")); + for (const CModule* pMod : Modules) { + Table.AddRow(); + Table.SetCell(t_s("Name", "listmods"), pMod->GetModName()); + Table.SetCell(t_s("Arguments", "listmods"), pMod->GetArgs()); + } + PutStatus(Table); + }; if (m_pUser->IsAdmin()) { - CModules& GModules = CZNC::Get().GetModules(); + const CModules& GModules = CZNC::Get().GetModules(); if (!GModules.size()) { - PutStatus("No global modules loaded."); + PutStatus(t_s("No global modules loaded.")); } else { - PutStatus("Global modules:"); - CTable GTable; - GTable.AddColumn("Name"); - GTable.AddColumn("Arguments"); - - for (const CModule* pMod : GModules) { - GTable.AddRow(); - GTable.SetCell("Name", pMod->GetModName()); - GTable.SetCell("Arguments", pMod->GetArgs()); - } - - PutStatus(GTable); + PutStatus(t_s("Global modules:")); + PrintModules(GModules); } } - CModules& Modules = m_pUser->GetModules(); + const CModules& UModules = m_pUser->GetModules(); - if (!Modules.size()) { - PutStatus("Your user has no modules loaded."); + if (!UModules.size()) { + PutStatus(t_s("Your user has no modules loaded.")); } else { - PutStatus("User modules:"); - CTable Table; - Table.AddColumn("Name"); - Table.AddColumn("Arguments"); - - for (const CModule* pMod : Modules) { - Table.AddRow(); - Table.SetCell("Name", pMod->GetModName()); - Table.SetCell("Arguments", pMod->GetArgs()); - } - - PutStatus(Table); + PutStatus(t_s("User modules:")); + PrintModules(UModules); } if (m_pNetwork) { - CModules& NetworkModules = m_pNetwork->GetModules(); + const CModules& NetworkModules = m_pNetwork->GetModules(); if (NetworkModules.empty()) { - PutStatus("This network has no modules loaded."); + PutStatus(t_s("This network has no modules loaded.")); } else { - PutStatus("Network modules:"); - CTable Table; - Table.AddColumn("Name"); - Table.AddColumn("Arguments"); - - for (const CModule* pMod : NetworkModules) { - Table.AddRow(); - Table.SetCell("Name", pMod->GetModName()); - Table.SetCell("Arguments", pMod->GetArgs()); - } - - PutStatus(Table); + PutStatus(t_s("Network modules:")); + PrintModules(NetworkModules); } } @@ -926,36 +929,40 @@ void CClient::UserCommand(CString& sLine) { } else if (sCommand.Equals("LISTAVAILMODS") || sCommand.Equals("LISTAVAILABLEMODULES")) { if (m_pUser->DenyLoadMod()) { - PutStatus("Access Denied."); + PutStatus(t_s("Access denied.")); return; } + const auto PrintModules = [this](const set& ssModules) { + CTable Table; + Table.AddColumn(t_s("Name", "listavailmods")); + Table.AddColumn(t_s("Description", "listavailmods")); + + for (const CModInfo& Info : ssModules) { + Table.AddRow(); + Table.SetCell( + t_s("Name", "listavailmods"), + (CZNC::Get().GetModules().FindModule(Info.GetName()) + ? "*" + : " ") + + Info.GetName()); + Table.SetCell(t_s("Description", "listavailmods"), + Info.GetDescription().Ellipsize(128)); + } + + PutStatus(Table); + }; + if (m_pUser->IsAdmin()) { set ssGlobalMods; CZNC::Get().GetModules().GetAvailableMods(ssGlobalMods, CModInfo::GlobalModule); if (ssGlobalMods.empty()) { - PutStatus("No global modules available."); + PutStatus(t_s("No global modules available.")); } else { - PutStatus("Global modules:"); - CTable GTable; - GTable.AddColumn("Name"); - GTable.AddColumn("Description"); - - for (const CModInfo& Info : ssGlobalMods) { - GTable.AddRow(); - GTable.SetCell( - "Name", - (CZNC::Get().GetModules().FindModule(Info.GetName()) - ? "*" - : " ") + - Info.GetName()); - GTable.SetCell("Description", - Info.GetDescription().Ellipsize(128)); - } - - PutStatus(GTable); + PutStatus(t_s("Global modules:")); + PrintModules(ssGlobalMods); } } @@ -963,25 +970,10 @@ void CClient::UserCommand(CString& sLine) { CZNC::Get().GetModules().GetAvailableMods(ssUserMods); if (ssUserMods.empty()) { - PutStatus("No user modules available."); + PutStatus(t_s("No user modules available.")); } else { - PutStatus("User modules:"); - CTable Table; - Table.AddColumn("Name"); - Table.AddColumn("Description"); - - for (const CModInfo& Info : ssUserMods) { - Table.AddRow(); - Table.SetCell( - "Name", - (m_pUser->GetModules().FindModule(Info.GetName()) ? "*" - : " ") + - Info.GetName()); - Table.SetCell("Description", - Info.GetDescription().Ellipsize(128)); - } - - PutStatus(Table); + PutStatus(t_s("User modules:")); + PrintModules(ssUserMods); } set ssNetworkMods; @@ -989,27 +981,10 @@ void CClient::UserCommand(CString& sLine) { CModInfo::NetworkModule); if (ssNetworkMods.empty()) { - PutStatus("No network modules available."); + PutStatus(t_s("No network modules available.")); } else { - PutStatus("Network modules:"); - CTable Table; - Table.AddColumn("Name"); - Table.AddColumn("Description"); - - for (const CModInfo& Info : ssNetworkMods) { - Table.AddRow(); - Table.SetCell( - "Name", - ((m_pNetwork && - m_pNetwork->GetModules().FindModule(Info.GetName())) - ? "*" - : " ") + - Info.GetName()); - Table.SetCell("Description", - Info.GetDescription().Ellipsize(128)); - } - - PutStatus(Table); + PutStatus(t_s("Network modules:")); + PrintModules(ssNetworkMods); } return; } else if (sCommand.Equals("LOADMOD") || sCommand.Equals("LOADMODULE")) { @@ -1034,21 +1009,20 @@ void CClient::UserCommand(CString& sLine) { } if (m_pUser->DenyLoadMod()) { - PutStatus("Unable to load [" + sMod + "]: Access Denied."); + PutStatus(t_f("Unable to load {1}: Access denied.")(sMod)); return; } if (sMod.empty()) { - PutStatus( - "Usage: LoadMod [--type=global|user|network] [args]"); + PutStatus(t_s( + "Usage: LoadMod [--type=global|user|network] [args]")); return; } CModInfo ModInfo; CString sRetMsg; if (!CZNC::Get().GetModules().GetModInfo(ModInfo, sMod, sRetMsg)) { - PutStatus("Unable to find modinfo [" + sMod + "] [" + sRetMsg + - "]"); + PutStatus(t_f("Unable to load {1}: {2}")(sMod, sRetMsg)); return; } @@ -1057,41 +1031,48 @@ void CClient::UserCommand(CString& sLine) { } if (eType == CModInfo::GlobalModule && !m_pUser->IsAdmin()) { - PutStatus("Unable to load global module [" + sMod + - "]: Access Denied."); + PutStatus( + t_f("Unable to load global module {1}: Access denied.")(sMod)); return; } if (eType == CModInfo::NetworkModule && !m_pNetwork) { - PutStatus("Unable to load network module [" + sMod + - "] Not connected with a network."); + PutStatus( + t_f("Unable to load network module {1}: Not connected with a " + "network.")(sMod)); return; } CString sModRet; - bool b = false; + bool bLoaded = false; switch (eType) { case CModInfo::GlobalModule: - b = CZNC::Get().GetModules().LoadModule( + bLoaded = CZNC::Get().GetModules().LoadModule( sMod, sArgs, eType, nullptr, nullptr, sModRet); break; case CModInfo::UserModule: - b = m_pUser->GetModules().LoadModule(sMod, sArgs, eType, + bLoaded = m_pUser->GetModules().LoadModule(sMod, sArgs, eType, m_pUser, nullptr, sModRet); break; case CModInfo::NetworkModule: - b = m_pNetwork->GetModules().LoadModule( + bLoaded = m_pNetwork->GetModules().LoadModule( sMod, sArgs, eType, m_pUser, m_pNetwork, sModRet); break; default: - sModRet = - "Unable to load module [" + sMod + "]: Unknown module type"; + sModRet = t_s("Unknown module type"); } - if (b) sModRet = "Loaded module [" + sMod + "] " + sModRet; + if (bLoaded) { + if (sModRet.empty()) { + PutStatus(t_f("Loaded module {1}")(sMod)); + } else { + PutStatus(t_f("Loaded module {1}: {2}")(sMod, sModRet)); + } + } else { + PutStatus(t_f("Unable to load module {1}: {2}")(sMod, sModRet)); + } - PutStatus(sModRet); return; } else if (sCommand.Equals("UNLOADMOD") || sCommand.Equals("UNLOADMODULE")) { @@ -1112,12 +1093,13 @@ void CClient::UserCommand(CString& sLine) { } if (m_pUser->DenyLoadMod()) { - PutStatus("Unable to unload [" + sMod + "] Access Denied."); + PutStatus(t_f("Unable to unload {1}: Access denied.")(sMod)); return; } if (sMod.empty()) { - PutStatus("Usage: UnloadMod [--type=global|user|network] "); + PutStatus( + t_s("Usage: UnloadMod [--type=global|user|network] ")); return; } @@ -1125,8 +1107,8 @@ void CClient::UserCommand(CString& sLine) { CModInfo ModInfo; CString sRetMsg; if (!CZNC::Get().GetModules().GetModInfo(ModInfo, sMod, sRetMsg)) { - PutStatus("Unable to find modinfo [" + sMod + "] [" + sRetMsg + - "]"); + PutStatus( + t_f("Unable to determine type of {1}: {2}")(sMod, sRetMsg)); return; } @@ -1134,14 +1116,15 @@ void CClient::UserCommand(CString& sLine) { } if (eType == CModInfo::GlobalModule && !m_pUser->IsAdmin()) { - PutStatus("Unable to unload global module [" + sMod + - "]: Access Denied."); + PutStatus(t_f("Unable to unload global module {1}: Access denied.")( + sMod)); return; } if (eType == CModInfo::NetworkModule && !m_pNetwork) { - PutStatus("Unable to unload network module [" + sMod + - "] Not connected with a network."); + PutStatus( + t_f("Unable to unload network module {1}: Not connected with a " + "network.")(sMod)); return; } @@ -1158,8 +1141,8 @@ void CClient::UserCommand(CString& sLine) { m_pNetwork->GetModules().UnloadModule(sMod, sModRet); break; default: - sModRet = "Unable to unload module [" + sMod + - "]: Unknown module type"; + sModRet = t_f( + "Unable to unload module {1}: Unknown module type")(sMod); } PutStatus(sModRet); @@ -1172,7 +1155,7 @@ void CClient::UserCommand(CString& sLine) { CString sArgs = sLine.Token(3, true); if (m_pUser->DenyLoadMod()) { - PutStatus("Unable to reload modules. Access Denied."); + PutStatus(t_s("Unable to reload modules. Access denied.")); return; } @@ -1193,8 +1176,8 @@ void CClient::UserCommand(CString& sLine) { if (sMod.empty()) { PutStatus( - "Usage: ReloadMod [--type=global|user|network] " - "[args]"); + t_s("Usage: ReloadMod [--type=global|user|network] " + "[args]")); return; } @@ -1202,8 +1185,7 @@ void CClient::UserCommand(CString& sLine) { CModInfo ModInfo; CString sRetMsg; if (!CZNC::Get().GetModules().GetModInfo(ModInfo, sMod, sRetMsg)) { - PutStatus("Unable to find modinfo for [" + sMod + "] [" + - sRetMsg + "]"); + PutStatus(t_f("Unable to reload {1}: {2}")(sMod, sRetMsg)); return; } @@ -1211,14 +1193,15 @@ void CClient::UserCommand(CString& sLine) { } if (eType == CModInfo::GlobalModule && !m_pUser->IsAdmin()) { - PutStatus("Unable to reload global module [" + sMod + - "]: Access Denied."); + PutStatus(t_f("Unable to reload global module {1}: Access denied.")( + sMod)); return; } if (eType == CModInfo::NetworkModule && !m_pNetwork) { - PutStatus("Unable to load network module [" + sMod + - "] Not connected with a network."); + PutStatus( + t_f("Unable to reload network module {1}: Not connected with a " + "network.")(sMod)); return; } @@ -1238,8 +1221,8 @@ void CClient::UserCommand(CString& sLine) { m_pNetwork, sModRet); break; default: - sModRet = "Unable to reload module [" + sMod + - "]: Unknown module type"; + sModRet = t_f( + "Unable to reload module {1}: Unknown module type")(sMod); } PutStatus(sModRet); @@ -1250,94 +1233,99 @@ void CClient::UserCommand(CString& sLine) { CString sMod = sLine.Token(1); if (sMod.empty()) { - PutStatus("Usage: UpdateMod "); + PutStatus(t_s("Usage: UpdateMod ")); return; } - PutStatus("Reloading [" + sMod + "] everywhere"); + PutStatus(t_f("Reloading {1} everywhere")(sMod)); if (CZNC::Get().UpdateModule(sMod)) { - PutStatus("Done"); + PutStatus(t_s("Done")); } else { - PutStatus("Done, but there were errors, [" + sMod + - "] could not be loaded everywhere."); + PutStatus( + t_f("Done, but there were errors, module {1} could not be " + "reloaded everywhere.")(sMod)); } } else if ((sCommand.Equals("SETBINDHOST") || sCommand.Equals("SETVHOST")) && (m_pUser->IsAdmin() || !m_pUser->DenySetBindHost())) { if (!m_pNetwork) { - PutStatus( + PutStatus(t_s( "You must be connected with a network to use this command. Try " - "SetUserBindHost instead"); + "SetUserBindHost instead")); return; } CString sArg = sLine.Token(1); if (sArg.empty()) { - PutStatus("Usage: SetBindHost "); + PutStatus(t_s("Usage: SetBindHost ")); return; } if (sArg.Equals(m_pNetwork->GetBindHost())) { - PutStatus("You already have this bind host!"); + PutStatus(t_s("You already have this bind host!")); return; } m_pNetwork->SetBindHost(sArg); - PutStatus("Set bind host for network [" + m_pNetwork->GetName() + - "] to [" + m_pNetwork->GetBindHost() + "]"); + PutStatus(t_f("Set bind host for network {1} to {2}")( + m_pNetwork->GetName(), m_pNetwork->GetBindHost())); } else if (sCommand.Equals("SETUSERBINDHOST") && (m_pUser->IsAdmin() || !m_pUser->DenySetBindHost())) { CString sArg = sLine.Token(1); if (sArg.empty()) { - PutStatus("Usage: SetUserBindHost "); + PutStatus(t_s("Usage: SetUserBindHost ")); return; } if (sArg.Equals(m_pUser->GetBindHost())) { - PutStatus("You already have this bind host!"); + PutStatus(t_s("You already have this bind host!")); return; } m_pUser->SetBindHost(sArg); - PutStatus("Set bind host to [" + m_pUser->GetBindHost() + "]"); + PutStatus(t_f("Set default bind host to {1}")(m_pUser->GetBindHost())); } else if ((sCommand.Equals("CLEARBINDHOST") || sCommand.Equals("CLEARVHOST")) && (m_pUser->IsAdmin() || !m_pUser->DenySetBindHost())) { if (!m_pNetwork) { - PutStatus( + PutStatus(t_s( "You must be connected with a network to use this command. Try " - "ClearUserBindHost instead"); + "ClearUserBindHost instead")); return; } m_pNetwork->SetBindHost(""); - PutStatus("Bind host cleared for this network."); + PutStatus(t_s("Bind host cleared for this network.")); } else if (sCommand.Equals("CLEARUSERBINDHOST") && (m_pUser->IsAdmin() || !m_pUser->DenySetBindHost())) { m_pUser->SetBindHost(""); - PutStatus("Bind host cleared for your user."); + PutStatus(t_s("Default bind host cleared for your user.")); } else if (sCommand.Equals("SHOWBINDHOST")) { - PutStatus("This user's default bind host " + - (m_pUser->GetBindHost().empty() - ? "not set" - : "is [" + m_pUser->GetBindHost() + "]")); + if (m_pUser->GetBindHost().empty()) { + PutStatus(t_s("This user's default bind host not set")); + } else { + PutStatus(t_f("This user's default bind host is {1}")( + m_pUser->GetBindHost())); + } if (m_pNetwork) { - PutStatus("This network's bind host " + - (m_pNetwork->GetBindHost().empty() - ? "not set" - : "is [" + m_pNetwork->GetBindHost() + "]")); + if (m_pNetwork->GetBindHost().empty()) { + PutStatus(t_s("This network's bind host not set")); + } else { + PutStatus(t_f("This network's default bind host is {1}")( + m_pNetwork->GetBindHost())); + } } } else if (sCommand.Equals("PLAYBUFFER")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sBuffer = sLine.Token(1); if (sBuffer.empty()) { - PutStatus("Usage: PlayBuffer <#chan|query>"); + PutStatus(t_s("Usage: PlayBuffer <#chan|query>")); return; } @@ -1345,17 +1333,17 @@ void CClient::UserCommand(CString& sLine) { CChan* pChan = m_pNetwork->FindChan(sBuffer); if (!pChan) { - PutStatus("You are not on [" + sBuffer + "]"); + PutStatus(t_f("You are not on {1}")(sBuffer)); return; } if (!pChan->IsOn()) { - PutStatus("You are not on [" + sBuffer + "] [trying]"); + PutStatus(t_f("You are not on {1} (trying to join)")(sBuffer)); return; } if (pChan->GetBuffer().IsEmpty()) { - PutStatus("The buffer for [" + sBuffer + "] is empty"); + PutStatus(t_f("The buffer for channel {1} is empty")(sBuffer)); return; } @@ -1364,12 +1352,12 @@ void CClient::UserCommand(CString& sLine) { CQuery* pQuery = m_pNetwork->FindQuery(sBuffer); if (!pQuery) { - PutStatus("No active query with [" + sBuffer + "]"); + PutStatus(t_f("No active query with {1}")(sBuffer)); return; } if (pQuery->GetBuffer().IsEmpty()) { - PutStatus("The buffer for [" + sBuffer + "] is empty"); + PutStatus(t_f("The buffer for {1} is empty")(sBuffer)); return; } @@ -1377,15 +1365,15 @@ void CClient::UserCommand(CString& sLine) { } } else if (sCommand.Equals("CLEARBUFFER")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sBuffer = sLine.Token(1); if (sBuffer.empty()) { - PutStatus("Usage: ClearBuffer <#chan|query>"); + PutStatus(t_s("Usage: ClearBuffer <#chan|query>")); return; } @@ -1404,32 +1392,33 @@ void CClient::UserCommand(CString& sLine) { m_pNetwork->DelQuery(pQuery->GetName()); } - PutStatus("[" + CString(uMatches) + "] buffers matching [" + sBuffer + - "] have been cleared"); + PutStatus(t_p("{1} buffer matching {2} has been cleared", + "{1} buffers matching {2} have been cleared", + uMatches)(uMatches, sBuffer)); } else if (sCommand.Equals("CLEARALLCHANNELBUFFERS")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } for (CChan* pChan : m_pNetwork->GetChans()) { pChan->ClearBuffer(); } - PutStatus("All channel buffers have been cleared"); + PutStatus(t_s("All channel buffers have been cleared")); } else if (sCommand.Equals("CLEARALLQUERYBUFFERS")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } m_pNetwork->ClearQueryBuffer(); - PutStatus("All query buffers have been cleared"); + PutStatus(t_s("All query buffers have been cleared")); } else if (sCommand.Equals("CLEARALLBUFFERS")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } @@ -1437,18 +1426,18 @@ void CClient::UserCommand(CString& sLine) { pChan->ClearBuffer(); } m_pNetwork->ClearQueryBuffer(); - PutStatus("All buffers have been cleared"); + PutStatus(t_s("All buffers have been cleared")); } else if (sCommand.Equals("SETBUFFER")) { if (!m_pNetwork) { - PutStatus( - "You must be connected with a network to use this command"); + PutStatus(t_s( + "You must be connected with a network to use this command")); return; } CString sBuffer = sLine.Token(1); if (sBuffer.empty()) { - PutStatus("Usage: SetBuffer <#chan|query> [linecount]"); + PutStatus(t_s("Usage: SetBuffer <#chan|query> [linecount]")); return; } @@ -1468,13 +1457,18 @@ void CClient::UserCommand(CString& sLine) { if (!pQuery->SetBufferCount(uLineCount)) uFail++; } - PutStatus("BufferCount for [" + CString(uMatches - uFail) + - "] buffer was set to [" + CString(uLineCount) + "]"); if (uFail > 0) { - PutStatus("Setting BufferCount failed for [" + CString(uFail) + - "] buffers, " - "max buffer count is " + - CString(CZNC::Get().GetMaxBufferSize())); + PutStatus(t_p("Setting buffer size failed for {1} buffer", + "Setting buffer size failed for {1} buffers", + uFail)(uFail)); + PutStatus(t_p("Maximum buffer size is {1} line", + "Maximum buffer size is {1} lines", + CZNC::Get().GetMaxBufferSize())( + CZNC::Get().GetMaxBufferSize())); + } else { + PutStatus(t_p("Size of every buffer was set to {1} line", + "Size of every buffer was set to {1} lines", + uLineCount)(uLineCount)); } } else if (m_pUser->IsAdmin() && sCommand.Equals("TRAFFIC")) { CZNC::TrafficStatsPair Users, ZNC, Total; @@ -1482,47 +1476,58 @@ void CClient::UserCommand(CString& sLine) { CZNC::Get().GetTrafficStats(Users, ZNC, Total); CTable Table; - Table.AddColumn("Username"); - Table.AddColumn("In"); - Table.AddColumn("Out"); - Table.AddColumn("Total"); + Table.AddColumn(t_s("Username", "trafficcmd")); + Table.AddColumn(t_s("In", "trafficcmd")); + Table.AddColumn(t_s("Out", "trafficcmd")); + Table.AddColumn(t_s("Total", "trafficcmd")); for (const auto& it : traffic) { Table.AddRow(); - Table.SetCell("Username", it.first); - Table.SetCell("In", CString::ToByteStr(it.second.first)); - Table.SetCell("Out", CString::ToByteStr(it.second.second)); - Table.SetCell("Total", CString::ToByteStr(it.second.first + - it.second.second)); + Table.SetCell(t_s("Username", "trafficcmd"), it.first); + Table.SetCell(t_s("In", "trafficcmd"), + CString::ToByteStr(it.second.first)); + Table.SetCell(t_s("Out", "trafficcmd"), + CString::ToByteStr(it.second.second)); + Table.SetCell( + t_s("Total", "trafficcmd"), + CString::ToByteStr(it.second.first + it.second.second)); } Table.AddRow(); - Table.SetCell("Username", ""); - Table.SetCell("In", CString::ToByteStr(Users.first)); - Table.SetCell("Out", CString::ToByteStr(Users.second)); - Table.SetCell("Total", CString::ToByteStr(Users.first + Users.second)); + Table.SetCell(t_s("Username", "trafficcmd"), + t_s("", "trafficcmd")); + Table.SetCell(t_s("In", "trafficcmd"), CString::ToByteStr(Users.first)); + Table.SetCell(t_s("Out", "trafficcmd"), + CString::ToByteStr(Users.second)); + Table.SetCell(t_s("Total", "trafficcmd"), + CString::ToByteStr(Users.first + Users.second)); Table.AddRow(); - Table.SetCell("Username", ""); - Table.SetCell("In", CString::ToByteStr(ZNC.first)); - Table.SetCell("Out", CString::ToByteStr(ZNC.second)); - Table.SetCell("Total", CString::ToByteStr(ZNC.first + ZNC.second)); + Table.SetCell(t_s("Username", "trafficcmd"), + t_s("", "trafficcmd")); + Table.SetCell(t_s("In", "trafficcmd"), CString::ToByteStr(ZNC.first)); + Table.SetCell(t_s("Out", "trafficcmd"), CString::ToByteStr(ZNC.second)); + Table.SetCell(t_s("Total", "trafficcmd"), + CString::ToByteStr(ZNC.first + ZNC.second)); Table.AddRow(); - Table.SetCell("Username", ""); - Table.SetCell("In", CString::ToByteStr(Total.first)); - Table.SetCell("Out", CString::ToByteStr(Total.second)); - Table.SetCell("Total", CString::ToByteStr(Total.first + Total.second)); + Table.SetCell(t_s("Username", "trafficcmd"), + t_s("", "trafficcmd")); + Table.SetCell(t_s("In", "trafficcmd"), CString::ToByteStr(Total.first)); + Table.SetCell(t_s("Out", "trafficcmd"), + CString::ToByteStr(Total.second)); + Table.SetCell(t_s("Total", "trafficcmd"), + CString::ToByteStr(Total.first + Total.second)); PutStatus(Table); } else if (sCommand.Equals("UPTIME")) { - PutStatus("Running for " + CZNC::Get().GetUptime()); + PutStatus(t_f("Running for {1}")(CZNC::Get().GetUptime())); } else if (m_pUser->IsAdmin() && (sCommand.Equals("LISTPORTS") || sCommand.Equals("ADDPORT") || sCommand.Equals("DELPORT"))) { UserPortCommand(sLine); } else { - PutStatus("Unknown command [" + sCommand + "] try 'Help'"); + PutStatus(t_s("Unknown command, try 'Help'")); } } @@ -1531,37 +1536,44 @@ void CClient::UserPortCommand(CString& sLine) { if (sCommand.Equals("LISTPORTS")) { CTable Table; - Table.AddColumn("Port"); - Table.AddColumn("BindHost"); - Table.AddColumn("SSL"); - Table.AddColumn("Proto"); - Table.AddColumn("IRC/Web"); - Table.AddColumn("URIPrefix"); + Table.AddColumn(t_s("Port", "listports")); + Table.AddColumn(t_s("BindHost", "listports")); + Table.AddColumn(t_s("SSL", "listports")); + Table.AddColumn(t_s("Protocol", "listports")); + Table.AddColumn(t_s("IRC", "listports")); + Table.AddColumn(t_s("Web", "listports")); - vector::const_iterator it; const vector& vpListeners = CZNC::Get().GetListeners(); for (const CListener* pListener : vpListeners) { Table.AddRow(); - Table.SetCell("Port", CString(pListener->GetPort())); - Table.SetCell("BindHost", (pListener->GetBindHost().empty() + Table.SetCell(t_s("Port", "listports"), CString(pListener->GetPort())); + Table.SetCell(t_s("BindHost", "listports"), (pListener->GetBindHost().empty() ? CString("*") : pListener->GetBindHost())); - Table.SetCell("SSL", CString(pListener->IsSSL())); + Table.SetCell(t_s("SSL", "listports"), + pListener->IsSSL() ? t_s("yes", "listports|ssl") + : t_s("no", "listports|ssl")); EAddrType eAddr = pListener->GetAddrType(); - Table.SetCell("Proto", - (eAddr == ADDR_ALL - ? "All" - : (eAddr == ADDR_IPV4ONLY ? "IPv4" : "IPv6"))); + Table.SetCell(t_s("Protocol", "listports"), + eAddr == ADDR_ALL ? t_s("IPv4 and IPv6", "listports") + : (eAddr == ADDR_IPV4ONLY + ? t_s("IPv4", "listports") + : t_s("IPv6", "listports"))); CListener::EAcceptType eAccept = pListener->GetAcceptType(); - Table.SetCell( - "IRC/Web", - (eAccept == CListener::ACCEPT_ALL - ? "All" - : (eAccept == CListener::ACCEPT_IRC ? "IRC" : "Web"))); - Table.SetCell("URIPrefix", pListener->GetURIPrefix() + "/"); + Table.SetCell(t_s("IRC", "listports"), + eAccept == CListener::ACCEPT_ALL || + eAccept == CListener::ACCEPT_IRC + ? t_s("yes", "listports|irc") + : t_s("no", "listports|irc")); + Table.SetCell(t_s("Web", "listports"), + eAccept == CListener::ACCEPT_ALL || + eAccept == CListener::ACCEPT_HTTP + ? t_f("yes, on {1}", "listports|irc")( + pListener->GetURIPrefix() + "/") + : t_s("no", "listports|web")); } PutStatus(Table); @@ -1601,8 +1613,8 @@ void CClient::UserPortCommand(CString& sLine) { if (sPort.empty() || sAddr.empty() || sAccept.empty()) { PutStatus( - "Usage: AddPort <[+]port> " - "[bindhost [uriprefix]]"); + t_s("Usage: AddPort <[+]port> " + "[bindhost [uriprefix]]")); } else { bool bSSL = (sPort.StartsWith("+")); const CString sBindHost = sLine.Token(4); @@ -1612,18 +1624,20 @@ void CClient::UserPortCommand(CString& sLine) { bSSL, eAddr, eAccept); if (!pListener->Listen()) { + auto e = errno; delete pListener; - PutStatus("Unable to bind [" + CString(strerror(errno)) + "]"); + PutStatus(t_f("Unable to bind: {1}")(CString(strerror(e)))); } else { - if (CZNC::Get().AddListener(pListener)) - PutStatus("Port Added"); - else - PutStatus("Error?!"); + if (CZNC::Get().AddListener(pListener)) { + PutStatus(t_s("Port added")); + } else { + PutStatus(t_s("Couldn't add port")); + } } } } else if (sCommand.Equals("DELPORT")) { if (sPort.empty() || sAddr.empty()) { - PutStatus("Usage: DelPort [bindhost]"); + PutStatus(t_s("Usage: DelPort [bindhost]")); } else { const CString sBindHost = sLine.Token(3); @@ -1632,9 +1646,9 @@ void CClient::UserPortCommand(CString& sLine) { if (pListener) { CZNC::Get().DelListener(pListener); - PutStatus("Deleted Port"); + PutStatus(t_s("Deleted Port")); } else { - PutStatus("Unable to find a matching port"); + PutStatus(t_s("Unable to find a matching port")); } } } From c8dabadebb72ceb38f52ab7b91eff88c2f2dac60 Mon Sep 17 00:00:00 2001 From: ZNC-Jenkins bot Date: Mon, 26 Mar 2018 08:46:59 +0100 Subject: [PATCH 05/20] Update translations from Crowdin (#1499) --- src/po/znc.de.po | 811 +++++++++++++++++++++++++++++++++++++++++++++- src/po/znc.pot | 811 +++++++++++++++++++++++++++++++++++++++++++++- src/po/znc.ru.po | 825 ++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 2444 insertions(+), 3 deletions(-) diff --git a/src/po/znc.de.po b/src/po/znc.de.po index 061ba0a9..c3fbe3c7 100644 --- a/src/po/znc.de.po +++ b/src/po/znc.de.po @@ -55,7 +55,20 @@ msgstr "" "code>\"). Sobald einige Web-fähige Module geladen wurden, wird das Menü " "größer." -#: ClientCommand.cpp:51 +#: Chan.cpp:638 +msgid "Buffer Playback..." +msgstr "" + +#: Chan.cpp:676 +msgid "Playback Complete." +msgstr "" + +#: ClientCommand.cpp:51 ClientCommand.cpp:115 ClientCommand.cpp:137 +#: ClientCommand.cpp:749 ClientCommand.cpp:768 ClientCommand.cpp:794 +#: ClientCommand.cpp:827 ClientCommand.cpp:840 ClientCommand.cpp:853 +#: ClientCommand.cpp:868 ClientCommand.cpp:1321 ClientCommand.cpp:1369 +#: ClientCommand.cpp:1401 ClientCommand.cpp:1412 ClientCommand.cpp:1421 +#: ClientCommand.cpp:1433 msgid "You must be connected with a network to use this command" msgstr "" "Sie müssen mit einem Netzwerk verbunden sein um diesen Befehl zu verwenden" @@ -75,3 +88,799 @@ msgstr "Sie sind nicht in [{1}] (wird versucht)" #: ClientCommand.cpp:79 msgid "No nicks on [{1}]" msgstr "Keine Nicks in [{1}]" + +#: ClientCommand.cpp:91 ClientCommand.cpp:106 +msgid "Nick" +msgstr "" + +#: ClientCommand.cpp:92 ClientCommand.cpp:107 +msgid "Ident" +msgstr "" + +#: ClientCommand.cpp:93 ClientCommand.cpp:108 +msgid "Host" +msgstr "" + +#: ClientCommand.cpp:122 +msgid "Usage: Attach <#chans>" +msgstr "" + +#: ClientCommand.cpp:129 ClientCommand.cpp:151 +msgid "There was {1} channel matching [{2}]" +msgid_plural "There were {1} channels matching [{2}]" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:132 +msgid "Attached {1} channel" +msgid_plural "Attached {2} channels" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:144 +msgid "Usage: Detach <#chans>" +msgstr "" + +#: ClientCommand.cpp:154 +msgid "Detached {1} channel" +msgid_plural "Detached {2} channels" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:161 +msgid "There is no MOTD set." +msgstr "" + +#: ClientCommand.cpp:167 +msgid "Rehashing succeeded!" +msgstr "" + +#: ClientCommand.cpp:169 +msgid "Rehashing failed: {1}" +msgstr "" + +#: ClientCommand.cpp:173 +msgid "Wrote config to {1}" +msgstr "" + +#: ClientCommand.cpp:175 +msgid "Error while trying to write config." +msgstr "" + +#: ClientCommand.cpp:455 +msgid "Usage: ListChans" +msgstr "" + +#: ClientCommand.cpp:462 +msgid "No such user [{1}]" +msgstr "" + +#: ClientCommand.cpp:468 +msgid "User [{1}] doesn't have network [{2}]" +msgstr "" + +#: ClientCommand.cpp:479 +msgid "There are no channels defined." +msgstr "" + +#: ClientCommand.cpp:484 ClientCommand.cpp:500 +msgctxt "listchans" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:485 ClientCommand.cpp:503 +msgctxt "listchans" +msgid "Status" +msgstr "" + +#: ClientCommand.cpp:486 ClientCommand.cpp:510 +msgctxt "listchans" +msgid "In config" +msgstr "" + +#: ClientCommand.cpp:487 ClientCommand.cpp:512 +msgctxt "listchans" +msgid "Buffer" +msgstr "" + +#: ClientCommand.cpp:488 ClientCommand.cpp:516 +msgctxt "listchans" +msgid "Clear" +msgstr "" + +#: ClientCommand.cpp:489 ClientCommand.cpp:521 +msgctxt "listchans" +msgid "Modes" +msgstr "" + +#: ClientCommand.cpp:490 ClientCommand.cpp:522 +msgctxt "listchans" +msgid "Users" +msgstr "" + +#: ClientCommand.cpp:505 +msgctxt "listchans" +msgid "Detached" +msgstr "" + +#: ClientCommand.cpp:506 +msgctxt "listchans" +msgid "Joined" +msgstr "" + +#: ClientCommand.cpp:507 +msgctxt "listchans" +msgid "Disabled" +msgstr "" + +#: ClientCommand.cpp:508 +msgctxt "listchans" +msgid "Trying" +msgstr "" + +#: ClientCommand.cpp:511 ClientCommand.cpp:519 +msgctxt "listchans" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:536 +msgid "Total: {1}, Joined: {2}, Detached: {3}, Disabled: {4}" +msgstr "" + +#: ClientCommand.cpp:541 +msgid "" +"Network number limit reached. Ask an admin to increase the limit for you, or " +"delete unneeded networks using /znc DelNetwork " +msgstr "" + +#: ClientCommand.cpp:550 +msgid "Usage: AddNetwork " +msgstr "" + +#: ClientCommand.cpp:554 +msgid "Network name should be alphanumeric" +msgstr "" + +#: ClientCommand.cpp:561 +msgid "" +"Network added. Use /znc JumpNetwork {1}, or connect to ZNC with username {2} " +"(instead of just {3}) to connect to it." +msgstr "" + +#: ClientCommand.cpp:566 +msgid "Unable to add that network" +msgstr "" + +#: ClientCommand.cpp:573 +msgid "Usage: DelNetwork " +msgstr "" + +#: ClientCommand.cpp:582 +msgid "Network deleted" +msgstr "" + +#: ClientCommand.cpp:585 +msgid "Failed to delete network, perhaps this network doesn't exist" +msgstr "" + +#: ClientCommand.cpp:595 +msgid "User {1} not found" +msgstr "" + +#: ClientCommand.cpp:603 ClientCommand.cpp:611 +msgctxt "listnetworks" +msgid "Network" +msgstr "" + +#: ClientCommand.cpp:604 ClientCommand.cpp:613 ClientCommand.cpp:622 +msgctxt "listnetworks" +msgid "On IRC" +msgstr "" + +#: ClientCommand.cpp:605 ClientCommand.cpp:615 +msgctxt "listnetworks" +msgid "IRC Server" +msgstr "" + +#: ClientCommand.cpp:606 ClientCommand.cpp:617 +msgctxt "listnetworks" +msgid "IRC User" +msgstr "" + +#: ClientCommand.cpp:607 ClientCommand.cpp:619 +msgctxt "listnetworks" +msgid "Channels" +msgstr "" + +#: ClientCommand.cpp:614 +msgctxt "listnetworks" +msgid "Yes" +msgstr "" + +#: ClientCommand.cpp:623 +msgctxt "listnetworks" +msgid "No" +msgstr "" + +#: ClientCommand.cpp:628 +msgctxt "listnetworks" +msgid "No networks" +msgstr "" + +#: ClientCommand.cpp:632 ClientCommand.cpp:932 +msgid "Access denied." +msgstr "" + +#: ClientCommand.cpp:643 +msgid "Usage: MoveNetwork [new network]" +msgstr "" + +#: ClientCommand.cpp:653 +msgid "Old user {1} not found." +msgstr "" + +#: ClientCommand.cpp:659 +msgid "Old network {1} not found." +msgstr "" + +#: ClientCommand.cpp:665 +msgid "New user {1} not found." +msgstr "" + +#: ClientCommand.cpp:670 +msgid "User {1} already has network {2}." +msgstr "" + +#: ClientCommand.cpp:676 +msgid "Invalid network name [{1}]" +msgstr "" + +#: ClientCommand.cpp:692 +msgid "Some files seem to be in {1}. You might want to move them to {2}" +msgstr "" + +#: ClientCommand.cpp:706 +msgid "Error adding network: {1}" +msgstr "" + +#: ClientCommand.cpp:718 +msgid "Success." +msgstr "" + +#: ClientCommand.cpp:721 +msgid "Copied the network to new user, but failed to delete old network" +msgstr "" + +#: ClientCommand.cpp:728 +msgid "No network supplied." +msgstr "" + +#: ClientCommand.cpp:733 +msgid "You are already connected with this network." +msgstr "" + +#: ClientCommand.cpp:739 +msgid "Switched to {1}" +msgstr "" + +#: ClientCommand.cpp:742 +msgid "You don't have a network named {1}" +msgstr "" + +#: ClientCommand.cpp:754 +msgid "Usage: AddServer [[+]port] [pass]" +msgstr "" + +#: ClientCommand.cpp:759 +msgid "Server added" +msgstr "" + +#: ClientCommand.cpp:762 +msgid "" +"Unable to add that server. Perhaps the server is already added or openssl is " +"disabled?" +msgstr "" + +#: ClientCommand.cpp:777 +msgid "Usage: DelServer [port] [pass]" +msgstr "" + +#: ClientCommand.cpp:782 ClientCommand.cpp:822 +msgid "You don't have any servers added." +msgstr "" + +#: ClientCommand.cpp:787 +msgid "Server removed" +msgstr "" + +#: ClientCommand.cpp:789 +msgid "No such server" +msgstr "" + +#: ClientCommand.cpp:802 ClientCommand.cpp:809 +msgctxt "listservers" +msgid "Host" +msgstr "" + +#: ClientCommand.cpp:803 ClientCommand.cpp:811 +msgctxt "listservers" +msgid "Port" +msgstr "" + +#: ClientCommand.cpp:804 ClientCommand.cpp:814 +msgctxt "listservers" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:805 ClientCommand.cpp:816 +msgctxt "listservers" +msgid "Password" +msgstr "" + +#: ClientCommand.cpp:815 +msgctxt "listservers|cell" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:832 +msgid "Usage: AddTrustedServerFingerprint " +msgstr "" + +#: ClientCommand.cpp:836 ClientCommand.cpp:849 +msgid "Done." +msgstr "" + +#: ClientCommand.cpp:845 +msgid "Usage: DelTrustedServerFingerprint " +msgstr "" + +#: ClientCommand.cpp:858 +msgid "No fingerprints added." +msgstr "" + +#: ClientCommand.cpp:874 ClientCommand.cpp:880 +msgctxt "topicscmd" +msgid "Channel" +msgstr "" + +#: ClientCommand.cpp:875 ClientCommand.cpp:881 +msgctxt "topicscmd" +msgid "Set By" +msgstr "" + +#: ClientCommand.cpp:876 ClientCommand.cpp:882 +msgctxt "topicscmd" +msgid "Topic" +msgstr "" + +#: ClientCommand.cpp:889 ClientCommand.cpp:893 +msgctxt "listmods" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:890 ClientCommand.cpp:894 +msgctxt "listmods" +msgid "Arguments" +msgstr "" + +#: ClientCommand.cpp:902 +msgid "No global modules loaded." +msgstr "" + +#: ClientCommand.cpp:904 ClientCommand.cpp:964 +msgid "Global modules:" +msgstr "" + +#: ClientCommand.cpp:912 +msgid "Your user has no modules loaded." +msgstr "" + +#: ClientCommand.cpp:914 ClientCommand.cpp:975 +msgid "User modules:" +msgstr "" + +#: ClientCommand.cpp:921 +msgid "This network has no modules loaded." +msgstr "" + +#: ClientCommand.cpp:923 ClientCommand.cpp:986 +msgid "Network modules:" +msgstr "" + +#: ClientCommand.cpp:938 ClientCommand.cpp:944 +msgctxt "listavailmods" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:939 ClientCommand.cpp:949 +msgctxt "listavailmods" +msgid "Description" +msgstr "" + +#: ClientCommand.cpp:962 +msgid "No global modules available." +msgstr "" + +#: ClientCommand.cpp:973 +msgid "No user modules available." +msgstr "" + +#: ClientCommand.cpp:984 +msgid "No network modules available." +msgstr "" + +#: ClientCommand.cpp:1012 +msgid "Unable to load {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1018 +msgid "Usage: LoadMod [--type=global|user|network] [args]" +msgstr "" + +#: ClientCommand.cpp:1025 +msgid "Unable to load {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1035 +msgid "Unable to load global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1041 +msgid "Unable to load network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1063 +msgid "Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1068 +msgid "Loaded module {1}" +msgstr "" + +#: ClientCommand.cpp:1070 +msgid "Loaded module {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1073 +msgid "Unable to load module {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1096 +msgid "Unable to unload {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1102 +msgid "Usage: UnloadMod [--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1111 +msgid "Unable to determine type of {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1119 +msgid "Unable to unload global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1126 +msgid "Unable to unload network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1145 +msgid "Unable to unload module {1}: Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1158 +msgid "Unable to reload modules. Access denied." +msgstr "" + +#: ClientCommand.cpp:1179 +msgid "Usage: ReloadMod [--type=global|user|network] [args]" +msgstr "" + +#: ClientCommand.cpp:1188 +msgid "Unable to reload {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1196 +msgid "Unable to reload global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1203 +msgid "Unable to reload network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1225 +msgid "Unable to reload module {1}: Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1236 +msgid "Usage: UpdateMod " +msgstr "" + +#: ClientCommand.cpp:1240 +msgid "Reloading {1} everywhere" +msgstr "" + +#: ClientCommand.cpp:1242 +msgid "Done" +msgstr "" + +#: ClientCommand.cpp:1245 +msgid "" +"Done, but there were errors, module {1} could not be reloaded everywhere." +msgstr "" + +#: ClientCommand.cpp:1253 +msgid "" +"You must be connected with a network to use this command. Try " +"SetUserBindHost instead" +msgstr "" + +#: ClientCommand.cpp:1260 +msgid "Usage: SetBindHost " +msgstr "" + +#: ClientCommand.cpp:1265 ClientCommand.cpp:1282 +msgid "You already have this bind host!" +msgstr "" + +#: ClientCommand.cpp:1270 +msgid "Set bind host for network {1} to {2}" +msgstr "" + +#: ClientCommand.cpp:1277 +msgid "Usage: SetUserBindHost " +msgstr "" + +#: ClientCommand.cpp:1287 +msgid "Set default bind host to {1}" +msgstr "" + +#: ClientCommand.cpp:1293 +msgid "" +"You must be connected with a network to use this command. Try " +"ClearUserBindHost instead" +msgstr "" + +#: ClientCommand.cpp:1298 +msgid "Bind host cleared for this network." +msgstr "" + +#: ClientCommand.cpp:1302 +msgid "Default bind host cleared for your user." +msgstr "" + +#: ClientCommand.cpp:1305 +msgid "This user's default bind host not set" +msgstr "" + +#: ClientCommand.cpp:1307 +msgid "This user's default bind host is {1}" +msgstr "" + +#: ClientCommand.cpp:1312 +msgid "This network's bind host not set" +msgstr "" + +#: ClientCommand.cpp:1314 +msgid "This network's default bind host is {1}" +msgstr "" + +#: ClientCommand.cpp:1328 +msgid "Usage: PlayBuffer <#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1336 +msgid "You are not on {1}" +msgstr "" + +#: ClientCommand.cpp:1341 +msgid "You are not on {1} (trying to join)" +msgstr "" + +#: ClientCommand.cpp:1346 +msgid "The buffer for channel {1} is empty" +msgstr "" + +#: ClientCommand.cpp:1355 +msgid "No active query with {1}" +msgstr "" + +#: ClientCommand.cpp:1360 +msgid "The buffer for {1} is empty" +msgstr "" + +#: ClientCommand.cpp:1376 +msgid "Usage: ClearBuffer <#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1395 +msgid "{1} buffer matching {2} has been cleared" +msgid_plural "{1} buffers matching {2} have been cleared" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1408 +msgid "All channel buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1417 +msgid "All query buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1429 +msgid "All buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1440 +msgid "Usage: SetBuffer <#chan|query> [linecount]" +msgstr "" + +#: ClientCommand.cpp:1461 +msgid "Setting buffer size failed for {1} buffer" +msgid_plural "Setting buffer size failed for {1} buffers" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1464 +msgid "Maximum buffer size is {1} line" +msgid_plural "Maximum buffer size is {1} lines" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1469 +msgid "Size of every buffer was set to {1} line" +msgid_plural "Size of every buffer was set to {1} lines" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1479 ClientCommand.cpp:1486 ClientCommand.cpp:1497 +#: ClientCommand.cpp:1506 ClientCommand.cpp:1514 +msgctxt "trafficcmd" +msgid "Username" +msgstr "" + +#: ClientCommand.cpp:1480 ClientCommand.cpp:1487 ClientCommand.cpp:1499 +#: ClientCommand.cpp:1508 ClientCommand.cpp:1516 +msgctxt "trafficcmd" +msgid "In" +msgstr "" + +#: ClientCommand.cpp:1481 ClientCommand.cpp:1489 ClientCommand.cpp:1500 +#: ClientCommand.cpp:1509 ClientCommand.cpp:1517 +msgctxt "trafficcmd" +msgid "Out" +msgstr "" + +#: ClientCommand.cpp:1482 ClientCommand.cpp:1492 ClientCommand.cpp:1502 +#: ClientCommand.cpp:1510 ClientCommand.cpp:1519 +msgctxt "trafficcmd" +msgid "Total" +msgstr "" + +#: ClientCommand.cpp:1498 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1507 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1515 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1524 +msgid "Running for {1}" +msgstr "" + +#: ClientCommand.cpp:1530 +msgid "Unknown command, try 'Help'" +msgstr "" + +#: ClientCommand.cpp:1539 ClientCommand.cpp:1550 +msgctxt "listports" +msgid "Port" +msgstr "" + +#: ClientCommand.cpp:1540 ClientCommand.cpp:1551 +msgctxt "listports" +msgid "BindHost" +msgstr "" + +#: ClientCommand.cpp:1541 ClientCommand.cpp:1554 +msgctxt "listports" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:1542 ClientCommand.cpp:1559 +msgctxt "listports" +msgid "Protocol" +msgstr "" + +#: ClientCommand.cpp:1543 ClientCommand.cpp:1566 +msgctxt "listports" +msgid "IRC" +msgstr "" + +#: ClientCommand.cpp:1544 ClientCommand.cpp:1571 +msgctxt "listports" +msgid "Web" +msgstr "" + +#: ClientCommand.cpp:1555 +msgctxt "listports|ssl" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:1556 +msgctxt "listports|ssl" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1560 +msgctxt "listports" +msgid "IPv4 and IPv6" +msgstr "" + +#: ClientCommand.cpp:1562 +msgctxt "listports" +msgid "IPv4" +msgstr "" + +#: ClientCommand.cpp:1563 +msgctxt "listports" +msgid "IPv6" +msgstr "" + +#: ClientCommand.cpp:1569 +msgctxt "listports|irc" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:1570 +msgctxt "listports|irc" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1574 +msgctxt "listports|irc" +msgid "yes, on {1}" +msgstr "" + +#: ClientCommand.cpp:1576 +msgctxt "listports|web" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1616 +msgid "" +"Usage: AddPort <[+]port> [bindhost [uriprefix]]" +msgstr "" + +#: ClientCommand.cpp:1629 +msgid "Unable to bind: {1}" +msgstr "" + +#: ClientCommand.cpp:1632 +msgid "Port added" +msgstr "" + +#: ClientCommand.cpp:1634 +msgid "Couldn't add port" +msgstr "" + +#: ClientCommand.cpp:1640 +msgid "Usage: DelPort [bindhost]" +msgstr "" + +#: ClientCommand.cpp:1649 +msgid "Deleted Port" +msgstr "" + +#: ClientCommand.cpp:1651 +msgid "Unable to find a matching port" +msgstr "" diff --git a/src/po/znc.pot b/src/po/znc.pot index 79a8dc59..8197f9cf 100644 --- a/src/po/znc.pot +++ b/src/po/znc.pot @@ -42,7 +42,20 @@ msgid "" "code>”). Once you have loaded some Web-enabled modules, the menu will expand." msgstr "" -#: ClientCommand.cpp:51 +#: Chan.cpp:638 +msgid "Buffer Playback..." +msgstr "" + +#: Chan.cpp:676 +msgid "Playback Complete." +msgstr "" + +#: ClientCommand.cpp:51 ClientCommand.cpp:115 ClientCommand.cpp:137 +#: ClientCommand.cpp:749 ClientCommand.cpp:768 ClientCommand.cpp:794 +#: ClientCommand.cpp:827 ClientCommand.cpp:840 ClientCommand.cpp:853 +#: ClientCommand.cpp:868 ClientCommand.cpp:1321 ClientCommand.cpp:1369 +#: ClientCommand.cpp:1401 ClientCommand.cpp:1412 ClientCommand.cpp:1421 +#: ClientCommand.cpp:1433 msgid "You must be connected with a network to use this command" msgstr "" @@ -61,3 +74,799 @@ msgstr "" #: ClientCommand.cpp:79 msgid "No nicks on [{1}]" msgstr "" + +#: ClientCommand.cpp:91 ClientCommand.cpp:106 +msgid "Nick" +msgstr "" + +#: ClientCommand.cpp:92 ClientCommand.cpp:107 +msgid "Ident" +msgstr "" + +#: ClientCommand.cpp:93 ClientCommand.cpp:108 +msgid "Host" +msgstr "" + +#: ClientCommand.cpp:122 +msgid "Usage: Attach <#chans>" +msgstr "" + +#: ClientCommand.cpp:129 ClientCommand.cpp:151 +msgid "There was {1} channel matching [{2}]" +msgid_plural "There were {1} channels matching [{2}]" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:132 +msgid "Attached {1} channel" +msgid_plural "Attached {2} channels" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:144 +msgid "Usage: Detach <#chans>" +msgstr "" + +#: ClientCommand.cpp:154 +msgid "Detached {1} channel" +msgid_plural "Detached {2} channels" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:161 +msgid "There is no MOTD set." +msgstr "" + +#: ClientCommand.cpp:167 +msgid "Rehashing succeeded!" +msgstr "" + +#: ClientCommand.cpp:169 +msgid "Rehashing failed: {1}" +msgstr "" + +#: ClientCommand.cpp:173 +msgid "Wrote config to {1}" +msgstr "" + +#: ClientCommand.cpp:175 +msgid "Error while trying to write config." +msgstr "" + +#: ClientCommand.cpp:455 +msgid "Usage: ListChans" +msgstr "" + +#: ClientCommand.cpp:462 +msgid "No such user [{1}]" +msgstr "" + +#: ClientCommand.cpp:468 +msgid "User [{1}] doesn't have network [{2}]" +msgstr "" + +#: ClientCommand.cpp:479 +msgid "There are no channels defined." +msgstr "" + +#: ClientCommand.cpp:484 ClientCommand.cpp:500 +msgctxt "listchans" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:485 ClientCommand.cpp:503 +msgctxt "listchans" +msgid "Status" +msgstr "" + +#: ClientCommand.cpp:486 ClientCommand.cpp:510 +msgctxt "listchans" +msgid "In config" +msgstr "" + +#: ClientCommand.cpp:487 ClientCommand.cpp:512 +msgctxt "listchans" +msgid "Buffer" +msgstr "" + +#: ClientCommand.cpp:488 ClientCommand.cpp:516 +msgctxt "listchans" +msgid "Clear" +msgstr "" + +#: ClientCommand.cpp:489 ClientCommand.cpp:521 +msgctxt "listchans" +msgid "Modes" +msgstr "" + +#: ClientCommand.cpp:490 ClientCommand.cpp:522 +msgctxt "listchans" +msgid "Users" +msgstr "" + +#: ClientCommand.cpp:505 +msgctxt "listchans" +msgid "Detached" +msgstr "" + +#: ClientCommand.cpp:506 +msgctxt "listchans" +msgid "Joined" +msgstr "" + +#: ClientCommand.cpp:507 +msgctxt "listchans" +msgid "Disabled" +msgstr "" + +#: ClientCommand.cpp:508 +msgctxt "listchans" +msgid "Trying" +msgstr "" + +#: ClientCommand.cpp:511 ClientCommand.cpp:519 +msgctxt "listchans" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:536 +msgid "Total: {1}, Joined: {2}, Detached: {3}, Disabled: {4}" +msgstr "" + +#: ClientCommand.cpp:541 +msgid "" +"Network number limit reached. Ask an admin to increase the limit for you, or " +"delete unneeded networks using /znc DelNetwork " +msgstr "" + +#: ClientCommand.cpp:550 +msgid "Usage: AddNetwork " +msgstr "" + +#: ClientCommand.cpp:554 +msgid "Network name should be alphanumeric" +msgstr "" + +#: ClientCommand.cpp:561 +msgid "" +"Network added. Use /znc JumpNetwork {1}, or connect to ZNC with username {2} " +"(instead of just {3}) to connect to it." +msgstr "" + +#: ClientCommand.cpp:566 +msgid "Unable to add that network" +msgstr "" + +#: ClientCommand.cpp:573 +msgid "Usage: DelNetwork " +msgstr "" + +#: ClientCommand.cpp:582 +msgid "Network deleted" +msgstr "" + +#: ClientCommand.cpp:585 +msgid "Failed to delete network, perhaps this network doesn't exist" +msgstr "" + +#: ClientCommand.cpp:595 +msgid "User {1} not found" +msgstr "" + +#: ClientCommand.cpp:603 ClientCommand.cpp:611 +msgctxt "listnetworks" +msgid "Network" +msgstr "" + +#: ClientCommand.cpp:604 ClientCommand.cpp:613 ClientCommand.cpp:622 +msgctxt "listnetworks" +msgid "On IRC" +msgstr "" + +#: ClientCommand.cpp:605 ClientCommand.cpp:615 +msgctxt "listnetworks" +msgid "IRC Server" +msgstr "" + +#: ClientCommand.cpp:606 ClientCommand.cpp:617 +msgctxt "listnetworks" +msgid "IRC User" +msgstr "" + +#: ClientCommand.cpp:607 ClientCommand.cpp:619 +msgctxt "listnetworks" +msgid "Channels" +msgstr "" + +#: ClientCommand.cpp:614 +msgctxt "listnetworks" +msgid "Yes" +msgstr "" + +#: ClientCommand.cpp:623 +msgctxt "listnetworks" +msgid "No" +msgstr "" + +#: ClientCommand.cpp:628 +msgctxt "listnetworks" +msgid "No networks" +msgstr "" + +#: ClientCommand.cpp:632 ClientCommand.cpp:932 +msgid "Access denied." +msgstr "" + +#: ClientCommand.cpp:643 +msgid "Usage: MoveNetwork [new network]" +msgstr "" + +#: ClientCommand.cpp:653 +msgid "Old user {1} not found." +msgstr "" + +#: ClientCommand.cpp:659 +msgid "Old network {1} not found." +msgstr "" + +#: ClientCommand.cpp:665 +msgid "New user {1} not found." +msgstr "" + +#: ClientCommand.cpp:670 +msgid "User {1} already has network {2}." +msgstr "" + +#: ClientCommand.cpp:676 +msgid "Invalid network name [{1}]" +msgstr "" + +#: ClientCommand.cpp:692 +msgid "Some files seem to be in {1}. You might want to move them to {2}" +msgstr "" + +#: ClientCommand.cpp:706 +msgid "Error adding network: {1}" +msgstr "" + +#: ClientCommand.cpp:718 +msgid "Success." +msgstr "" + +#: ClientCommand.cpp:721 +msgid "Copied the network to new user, but failed to delete old network" +msgstr "" + +#: ClientCommand.cpp:728 +msgid "No network supplied." +msgstr "" + +#: ClientCommand.cpp:733 +msgid "You are already connected with this network." +msgstr "" + +#: ClientCommand.cpp:739 +msgid "Switched to {1}" +msgstr "" + +#: ClientCommand.cpp:742 +msgid "You don't have a network named {1}" +msgstr "" + +#: ClientCommand.cpp:754 +msgid "Usage: AddServer [[+]port] [pass]" +msgstr "" + +#: ClientCommand.cpp:759 +msgid "Server added" +msgstr "" + +#: ClientCommand.cpp:762 +msgid "" +"Unable to add that server. Perhaps the server is already added or openssl is " +"disabled?" +msgstr "" + +#: ClientCommand.cpp:777 +msgid "Usage: DelServer [port] [pass]" +msgstr "" + +#: ClientCommand.cpp:782 ClientCommand.cpp:822 +msgid "You don't have any servers added." +msgstr "" + +#: ClientCommand.cpp:787 +msgid "Server removed" +msgstr "" + +#: ClientCommand.cpp:789 +msgid "No such server" +msgstr "" + +#: ClientCommand.cpp:802 ClientCommand.cpp:809 +msgctxt "listservers" +msgid "Host" +msgstr "" + +#: ClientCommand.cpp:803 ClientCommand.cpp:811 +msgctxt "listservers" +msgid "Port" +msgstr "" + +#: ClientCommand.cpp:804 ClientCommand.cpp:814 +msgctxt "listservers" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:805 ClientCommand.cpp:816 +msgctxt "listservers" +msgid "Password" +msgstr "" + +#: ClientCommand.cpp:815 +msgctxt "listservers|cell" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:832 +msgid "Usage: AddTrustedServerFingerprint " +msgstr "" + +#: ClientCommand.cpp:836 ClientCommand.cpp:849 +msgid "Done." +msgstr "" + +#: ClientCommand.cpp:845 +msgid "Usage: DelTrustedServerFingerprint " +msgstr "" + +#: ClientCommand.cpp:858 +msgid "No fingerprints added." +msgstr "" + +#: ClientCommand.cpp:874 ClientCommand.cpp:880 +msgctxt "topicscmd" +msgid "Channel" +msgstr "" + +#: ClientCommand.cpp:875 ClientCommand.cpp:881 +msgctxt "topicscmd" +msgid "Set By" +msgstr "" + +#: ClientCommand.cpp:876 ClientCommand.cpp:882 +msgctxt "topicscmd" +msgid "Topic" +msgstr "" + +#: ClientCommand.cpp:889 ClientCommand.cpp:893 +msgctxt "listmods" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:890 ClientCommand.cpp:894 +msgctxt "listmods" +msgid "Arguments" +msgstr "" + +#: ClientCommand.cpp:902 +msgid "No global modules loaded." +msgstr "" + +#: ClientCommand.cpp:904 ClientCommand.cpp:964 +msgid "Global modules:" +msgstr "" + +#: ClientCommand.cpp:912 +msgid "Your user has no modules loaded." +msgstr "" + +#: ClientCommand.cpp:914 ClientCommand.cpp:975 +msgid "User modules:" +msgstr "" + +#: ClientCommand.cpp:921 +msgid "This network has no modules loaded." +msgstr "" + +#: ClientCommand.cpp:923 ClientCommand.cpp:986 +msgid "Network modules:" +msgstr "" + +#: ClientCommand.cpp:938 ClientCommand.cpp:944 +msgctxt "listavailmods" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:939 ClientCommand.cpp:949 +msgctxt "listavailmods" +msgid "Description" +msgstr "" + +#: ClientCommand.cpp:962 +msgid "No global modules available." +msgstr "" + +#: ClientCommand.cpp:973 +msgid "No user modules available." +msgstr "" + +#: ClientCommand.cpp:984 +msgid "No network modules available." +msgstr "" + +#: ClientCommand.cpp:1012 +msgid "Unable to load {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1018 +msgid "Usage: LoadMod [--type=global|user|network] [args]" +msgstr "" + +#: ClientCommand.cpp:1025 +msgid "Unable to load {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1035 +msgid "Unable to load global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1041 +msgid "Unable to load network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1063 +msgid "Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1068 +msgid "Loaded module {1}" +msgstr "" + +#: ClientCommand.cpp:1070 +msgid "Loaded module {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1073 +msgid "Unable to load module {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1096 +msgid "Unable to unload {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1102 +msgid "Usage: UnloadMod [--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1111 +msgid "Unable to determine type of {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1119 +msgid "Unable to unload global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1126 +msgid "Unable to unload network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1145 +msgid "Unable to unload module {1}: Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1158 +msgid "Unable to reload modules. Access denied." +msgstr "" + +#: ClientCommand.cpp:1179 +msgid "Usage: ReloadMod [--type=global|user|network] [args]" +msgstr "" + +#: ClientCommand.cpp:1188 +msgid "Unable to reload {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1196 +msgid "Unable to reload global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1203 +msgid "Unable to reload network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1225 +msgid "Unable to reload module {1}: Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1236 +msgid "Usage: UpdateMod " +msgstr "" + +#: ClientCommand.cpp:1240 +msgid "Reloading {1} everywhere" +msgstr "" + +#: ClientCommand.cpp:1242 +msgid "Done" +msgstr "" + +#: ClientCommand.cpp:1245 +msgid "" +"Done, but there were errors, module {1} could not be reloaded everywhere." +msgstr "" + +#: ClientCommand.cpp:1253 +msgid "" +"You must be connected with a network to use this command. Try " +"SetUserBindHost instead" +msgstr "" + +#: ClientCommand.cpp:1260 +msgid "Usage: SetBindHost " +msgstr "" + +#: ClientCommand.cpp:1265 ClientCommand.cpp:1282 +msgid "You already have this bind host!" +msgstr "" + +#: ClientCommand.cpp:1270 +msgid "Set bind host for network {1} to {2}" +msgstr "" + +#: ClientCommand.cpp:1277 +msgid "Usage: SetUserBindHost " +msgstr "" + +#: ClientCommand.cpp:1287 +msgid "Set default bind host to {1}" +msgstr "" + +#: ClientCommand.cpp:1293 +msgid "" +"You must be connected with a network to use this command. Try " +"ClearUserBindHost instead" +msgstr "" + +#: ClientCommand.cpp:1298 +msgid "Bind host cleared for this network." +msgstr "" + +#: ClientCommand.cpp:1302 +msgid "Default bind host cleared for your user." +msgstr "" + +#: ClientCommand.cpp:1305 +msgid "This user's default bind host not set" +msgstr "" + +#: ClientCommand.cpp:1307 +msgid "This user's default bind host is {1}" +msgstr "" + +#: ClientCommand.cpp:1312 +msgid "This network's bind host not set" +msgstr "" + +#: ClientCommand.cpp:1314 +msgid "This network's default bind host is {1}" +msgstr "" + +#: ClientCommand.cpp:1328 +msgid "Usage: PlayBuffer <#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1336 +msgid "You are not on {1}" +msgstr "" + +#: ClientCommand.cpp:1341 +msgid "You are not on {1} (trying to join)" +msgstr "" + +#: ClientCommand.cpp:1346 +msgid "The buffer for channel {1} is empty" +msgstr "" + +#: ClientCommand.cpp:1355 +msgid "No active query with {1}" +msgstr "" + +#: ClientCommand.cpp:1360 +msgid "The buffer for {1} is empty" +msgstr "" + +#: ClientCommand.cpp:1376 +msgid "Usage: ClearBuffer <#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1395 +msgid "{1} buffer matching {2} has been cleared" +msgid_plural "{1} buffers matching {2} have been cleared" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1408 +msgid "All channel buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1417 +msgid "All query buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1429 +msgid "All buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1440 +msgid "Usage: SetBuffer <#chan|query> [linecount]" +msgstr "" + +#: ClientCommand.cpp:1461 +msgid "Setting buffer size failed for {1} buffer" +msgid_plural "Setting buffer size failed for {1} buffers" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1464 +msgid "Maximum buffer size is {1} line" +msgid_plural "Maximum buffer size is {1} lines" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1469 +msgid "Size of every buffer was set to {1} line" +msgid_plural "Size of every buffer was set to {1} lines" +msgstr[0] "" +msgstr[1] "" + +#: ClientCommand.cpp:1479 ClientCommand.cpp:1486 ClientCommand.cpp:1497 +#: ClientCommand.cpp:1506 ClientCommand.cpp:1514 +msgctxt "trafficcmd" +msgid "Username" +msgstr "" + +#: ClientCommand.cpp:1480 ClientCommand.cpp:1487 ClientCommand.cpp:1499 +#: ClientCommand.cpp:1508 ClientCommand.cpp:1516 +msgctxt "trafficcmd" +msgid "In" +msgstr "" + +#: ClientCommand.cpp:1481 ClientCommand.cpp:1489 ClientCommand.cpp:1500 +#: ClientCommand.cpp:1509 ClientCommand.cpp:1517 +msgctxt "trafficcmd" +msgid "Out" +msgstr "" + +#: ClientCommand.cpp:1482 ClientCommand.cpp:1492 ClientCommand.cpp:1502 +#: ClientCommand.cpp:1510 ClientCommand.cpp:1519 +msgctxt "trafficcmd" +msgid "Total" +msgstr "" + +#: ClientCommand.cpp:1498 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1507 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1515 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1524 +msgid "Running for {1}" +msgstr "" + +#: ClientCommand.cpp:1530 +msgid "Unknown command, try 'Help'" +msgstr "" + +#: ClientCommand.cpp:1539 ClientCommand.cpp:1550 +msgctxt "listports" +msgid "Port" +msgstr "" + +#: ClientCommand.cpp:1540 ClientCommand.cpp:1551 +msgctxt "listports" +msgid "BindHost" +msgstr "" + +#: ClientCommand.cpp:1541 ClientCommand.cpp:1554 +msgctxt "listports" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:1542 ClientCommand.cpp:1559 +msgctxt "listports" +msgid "Protocol" +msgstr "" + +#: ClientCommand.cpp:1543 ClientCommand.cpp:1566 +msgctxt "listports" +msgid "IRC" +msgstr "" + +#: ClientCommand.cpp:1544 ClientCommand.cpp:1571 +msgctxt "listports" +msgid "Web" +msgstr "" + +#: ClientCommand.cpp:1555 +msgctxt "listports|ssl" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:1556 +msgctxt "listports|ssl" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1560 +msgctxt "listports" +msgid "IPv4 and IPv6" +msgstr "" + +#: ClientCommand.cpp:1562 +msgctxt "listports" +msgid "IPv4" +msgstr "" + +#: ClientCommand.cpp:1563 +msgctxt "listports" +msgid "IPv6" +msgstr "" + +#: ClientCommand.cpp:1569 +msgctxt "listports|irc" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:1570 +msgctxt "listports|irc" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1574 +msgctxt "listports|irc" +msgid "yes, on {1}" +msgstr "" + +#: ClientCommand.cpp:1576 +msgctxt "listports|web" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1616 +msgid "" +"Usage: AddPort <[+]port> [bindhost [uriprefix]]" +msgstr "" + +#: ClientCommand.cpp:1629 +msgid "Unable to bind: {1}" +msgstr "" + +#: ClientCommand.cpp:1632 +msgid "Port added" +msgstr "" + +#: ClientCommand.cpp:1634 +msgid "Couldn't add port" +msgstr "" + +#: ClientCommand.cpp:1640 +msgid "Usage: DelPort [bindhost]" +msgstr "" + +#: ClientCommand.cpp:1649 +msgid "Deleted Port" +msgstr "" + +#: ClientCommand.cpp:1651 +msgid "Unable to find a matching port" +msgstr "" diff --git a/src/po/znc.ru.po b/src/po/znc.ru.po index ebe4300d..a2bcdb4a 100644 --- a/src/po/znc.ru.po +++ b/src/po/znc.ru.po @@ -57,7 +57,20 @@ msgstr "" "модуль>»). Когда такие модули будут загружены, они будут доступны " "в меню сбоку." -#: ClientCommand.cpp:51 +#: Chan.cpp:638 +msgid "Buffer Playback..." +msgstr "" + +#: Chan.cpp:676 +msgid "Playback Complete." +msgstr "" + +#: ClientCommand.cpp:51 ClientCommand.cpp:115 ClientCommand.cpp:137 +#: ClientCommand.cpp:749 ClientCommand.cpp:768 ClientCommand.cpp:794 +#: ClientCommand.cpp:827 ClientCommand.cpp:840 ClientCommand.cpp:853 +#: ClientCommand.cpp:868 ClientCommand.cpp:1321 ClientCommand.cpp:1369 +#: ClientCommand.cpp:1401 ClientCommand.cpp:1412 ClientCommand.cpp:1421 +#: ClientCommand.cpp:1433 msgid "You must be connected with a network to use this command" msgstr "" @@ -76,3 +89,813 @@ msgstr "" #: ClientCommand.cpp:79 msgid "No nicks on [{1}]" msgstr "" + +#: ClientCommand.cpp:91 ClientCommand.cpp:106 +msgid "Nick" +msgstr "" + +#: ClientCommand.cpp:92 ClientCommand.cpp:107 +msgid "Ident" +msgstr "" + +#: ClientCommand.cpp:93 ClientCommand.cpp:108 +msgid "Host" +msgstr "" + +#: ClientCommand.cpp:122 +msgid "Usage: Attach <#chans>" +msgstr "" + +#: ClientCommand.cpp:129 ClientCommand.cpp:151 +msgid "There was {1} channel matching [{2}]" +msgid_plural "There were {1} channels matching [{2}]" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:132 +msgid "Attached {1} channel" +msgid_plural "Attached {2} channels" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:144 +msgid "Usage: Detach <#chans>" +msgstr "" + +#: ClientCommand.cpp:154 +msgid "Detached {1} channel" +msgid_plural "Detached {2} channels" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:161 +msgid "There is no MOTD set." +msgstr "" + +#: ClientCommand.cpp:167 +msgid "Rehashing succeeded!" +msgstr "" + +#: ClientCommand.cpp:169 +msgid "Rehashing failed: {1}" +msgstr "" + +#: ClientCommand.cpp:173 +msgid "Wrote config to {1}" +msgstr "" + +#: ClientCommand.cpp:175 +msgid "Error while trying to write config." +msgstr "" + +#: ClientCommand.cpp:455 +msgid "Usage: ListChans" +msgstr "" + +#: ClientCommand.cpp:462 +msgid "No such user [{1}]" +msgstr "" + +#: ClientCommand.cpp:468 +msgid "User [{1}] doesn't have network [{2}]" +msgstr "" + +#: ClientCommand.cpp:479 +msgid "There are no channels defined." +msgstr "" + +#: ClientCommand.cpp:484 ClientCommand.cpp:500 +msgctxt "listchans" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:485 ClientCommand.cpp:503 +msgctxt "listchans" +msgid "Status" +msgstr "" + +#: ClientCommand.cpp:486 ClientCommand.cpp:510 +msgctxt "listchans" +msgid "In config" +msgstr "" + +#: ClientCommand.cpp:487 ClientCommand.cpp:512 +msgctxt "listchans" +msgid "Buffer" +msgstr "" + +#: ClientCommand.cpp:488 ClientCommand.cpp:516 +msgctxt "listchans" +msgid "Clear" +msgstr "" + +#: ClientCommand.cpp:489 ClientCommand.cpp:521 +msgctxt "listchans" +msgid "Modes" +msgstr "" + +#: ClientCommand.cpp:490 ClientCommand.cpp:522 +msgctxt "listchans" +msgid "Users" +msgstr "" + +#: ClientCommand.cpp:505 +msgctxt "listchans" +msgid "Detached" +msgstr "" + +#: ClientCommand.cpp:506 +msgctxt "listchans" +msgid "Joined" +msgstr "" + +#: ClientCommand.cpp:507 +msgctxt "listchans" +msgid "Disabled" +msgstr "" + +#: ClientCommand.cpp:508 +msgctxt "listchans" +msgid "Trying" +msgstr "" + +#: ClientCommand.cpp:511 ClientCommand.cpp:519 +msgctxt "listchans" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:536 +msgid "Total: {1}, Joined: {2}, Detached: {3}, Disabled: {4}" +msgstr "" + +#: ClientCommand.cpp:541 +msgid "" +"Network number limit reached. Ask an admin to increase the limit for you, or " +"delete unneeded networks using /znc DelNetwork " +msgstr "" + +#: ClientCommand.cpp:550 +msgid "Usage: AddNetwork " +msgstr "" + +#: ClientCommand.cpp:554 +msgid "Network name should be alphanumeric" +msgstr "" + +#: ClientCommand.cpp:561 +msgid "" +"Network added. Use /znc JumpNetwork {1}, or connect to ZNC with username {2} " +"(instead of just {3}) to connect to it." +msgstr "" + +#: ClientCommand.cpp:566 +msgid "Unable to add that network" +msgstr "" + +#: ClientCommand.cpp:573 +msgid "Usage: DelNetwork " +msgstr "" + +#: ClientCommand.cpp:582 +msgid "Network deleted" +msgstr "" + +#: ClientCommand.cpp:585 +msgid "Failed to delete network, perhaps this network doesn't exist" +msgstr "" + +#: ClientCommand.cpp:595 +msgid "User {1} not found" +msgstr "" + +#: ClientCommand.cpp:603 ClientCommand.cpp:611 +msgctxt "listnetworks" +msgid "Network" +msgstr "" + +#: ClientCommand.cpp:604 ClientCommand.cpp:613 ClientCommand.cpp:622 +msgctxt "listnetworks" +msgid "On IRC" +msgstr "" + +#: ClientCommand.cpp:605 ClientCommand.cpp:615 +msgctxt "listnetworks" +msgid "IRC Server" +msgstr "" + +#: ClientCommand.cpp:606 ClientCommand.cpp:617 +msgctxt "listnetworks" +msgid "IRC User" +msgstr "" + +#: ClientCommand.cpp:607 ClientCommand.cpp:619 +msgctxt "listnetworks" +msgid "Channels" +msgstr "" + +#: ClientCommand.cpp:614 +msgctxt "listnetworks" +msgid "Yes" +msgstr "" + +#: ClientCommand.cpp:623 +msgctxt "listnetworks" +msgid "No" +msgstr "" + +#: ClientCommand.cpp:628 +msgctxt "listnetworks" +msgid "No networks" +msgstr "" + +#: ClientCommand.cpp:632 ClientCommand.cpp:932 +msgid "Access denied." +msgstr "" + +#: ClientCommand.cpp:643 +msgid "Usage: MoveNetwork [new network]" +msgstr "" + +#: ClientCommand.cpp:653 +msgid "Old user {1} not found." +msgstr "" + +#: ClientCommand.cpp:659 +msgid "Old network {1} not found." +msgstr "" + +#: ClientCommand.cpp:665 +msgid "New user {1} not found." +msgstr "" + +#: ClientCommand.cpp:670 +msgid "User {1} already has network {2}." +msgstr "" + +#: ClientCommand.cpp:676 +msgid "Invalid network name [{1}]" +msgstr "" + +#: ClientCommand.cpp:692 +msgid "Some files seem to be in {1}. You might want to move them to {2}" +msgstr "" + +#: ClientCommand.cpp:706 +msgid "Error adding network: {1}" +msgstr "" + +#: ClientCommand.cpp:718 +msgid "Success." +msgstr "" + +#: ClientCommand.cpp:721 +msgid "Copied the network to new user, but failed to delete old network" +msgstr "" + +#: ClientCommand.cpp:728 +msgid "No network supplied." +msgstr "" + +#: ClientCommand.cpp:733 +msgid "You are already connected with this network." +msgstr "" + +#: ClientCommand.cpp:739 +msgid "Switched to {1}" +msgstr "" + +#: ClientCommand.cpp:742 +msgid "You don't have a network named {1}" +msgstr "" + +#: ClientCommand.cpp:754 +msgid "Usage: AddServer [[+]port] [pass]" +msgstr "" + +#: ClientCommand.cpp:759 +msgid "Server added" +msgstr "" + +#: ClientCommand.cpp:762 +msgid "" +"Unable to add that server. Perhaps the server is already added or openssl is " +"disabled?" +msgstr "" + +#: ClientCommand.cpp:777 +msgid "Usage: DelServer [port] [pass]" +msgstr "" + +#: ClientCommand.cpp:782 ClientCommand.cpp:822 +msgid "You don't have any servers added." +msgstr "" + +#: ClientCommand.cpp:787 +msgid "Server removed" +msgstr "" + +#: ClientCommand.cpp:789 +msgid "No such server" +msgstr "" + +#: ClientCommand.cpp:802 ClientCommand.cpp:809 +msgctxt "listservers" +msgid "Host" +msgstr "" + +#: ClientCommand.cpp:803 ClientCommand.cpp:811 +msgctxt "listservers" +msgid "Port" +msgstr "" + +#: ClientCommand.cpp:804 ClientCommand.cpp:814 +msgctxt "listservers" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:805 ClientCommand.cpp:816 +msgctxt "listservers" +msgid "Password" +msgstr "" + +#: ClientCommand.cpp:815 +msgctxt "listservers|cell" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:832 +msgid "Usage: AddTrustedServerFingerprint " +msgstr "" + +#: ClientCommand.cpp:836 ClientCommand.cpp:849 +msgid "Done." +msgstr "" + +#: ClientCommand.cpp:845 +msgid "Usage: DelTrustedServerFingerprint " +msgstr "" + +#: ClientCommand.cpp:858 +msgid "No fingerprints added." +msgstr "" + +#: ClientCommand.cpp:874 ClientCommand.cpp:880 +msgctxt "topicscmd" +msgid "Channel" +msgstr "" + +#: ClientCommand.cpp:875 ClientCommand.cpp:881 +msgctxt "topicscmd" +msgid "Set By" +msgstr "" + +#: ClientCommand.cpp:876 ClientCommand.cpp:882 +msgctxt "topicscmd" +msgid "Topic" +msgstr "" + +#: ClientCommand.cpp:889 ClientCommand.cpp:893 +msgctxt "listmods" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:890 ClientCommand.cpp:894 +msgctxt "listmods" +msgid "Arguments" +msgstr "" + +#: ClientCommand.cpp:902 +msgid "No global modules loaded." +msgstr "" + +#: ClientCommand.cpp:904 ClientCommand.cpp:964 +msgid "Global modules:" +msgstr "" + +#: ClientCommand.cpp:912 +msgid "Your user has no modules loaded." +msgstr "" + +#: ClientCommand.cpp:914 ClientCommand.cpp:975 +msgid "User modules:" +msgstr "" + +#: ClientCommand.cpp:921 +msgid "This network has no modules loaded." +msgstr "" + +#: ClientCommand.cpp:923 ClientCommand.cpp:986 +msgid "Network modules:" +msgstr "" + +#: ClientCommand.cpp:938 ClientCommand.cpp:944 +msgctxt "listavailmods" +msgid "Name" +msgstr "" + +#: ClientCommand.cpp:939 ClientCommand.cpp:949 +msgctxt "listavailmods" +msgid "Description" +msgstr "" + +#: ClientCommand.cpp:962 +msgid "No global modules available." +msgstr "" + +#: ClientCommand.cpp:973 +msgid "No user modules available." +msgstr "" + +#: ClientCommand.cpp:984 +msgid "No network modules available." +msgstr "" + +#: ClientCommand.cpp:1012 +msgid "Unable to load {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1018 +msgid "Usage: LoadMod [--type=global|user|network] [args]" +msgstr "" + +#: ClientCommand.cpp:1025 +msgid "Unable to load {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1035 +msgid "Unable to load global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1041 +msgid "Unable to load network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1063 +msgid "Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1068 +msgid "Loaded module {1}" +msgstr "" + +#: ClientCommand.cpp:1070 +msgid "Loaded module {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1073 +msgid "Unable to load module {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1096 +msgid "Unable to unload {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1102 +msgid "Usage: UnloadMod [--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1111 +msgid "Unable to determine type of {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1119 +msgid "Unable to unload global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1126 +msgid "Unable to unload network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1145 +msgid "Unable to unload module {1}: Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1158 +msgid "Unable to reload modules. Access denied." +msgstr "" + +#: ClientCommand.cpp:1179 +msgid "Usage: ReloadMod [--type=global|user|network] [args]" +msgstr "" + +#: ClientCommand.cpp:1188 +msgid "Unable to reload {1}: {2}" +msgstr "" + +#: ClientCommand.cpp:1196 +msgid "Unable to reload global module {1}: Access denied." +msgstr "" + +#: ClientCommand.cpp:1203 +msgid "Unable to reload network module {1}: Not connected with a network." +msgstr "" + +#: ClientCommand.cpp:1225 +msgid "Unable to reload module {1}: Unknown module type" +msgstr "" + +#: ClientCommand.cpp:1236 +msgid "Usage: UpdateMod " +msgstr "" + +#: ClientCommand.cpp:1240 +msgid "Reloading {1} everywhere" +msgstr "" + +#: ClientCommand.cpp:1242 +msgid "Done" +msgstr "" + +#: ClientCommand.cpp:1245 +msgid "" +"Done, but there were errors, module {1} could not be reloaded everywhere." +msgstr "" + +#: ClientCommand.cpp:1253 +msgid "" +"You must be connected with a network to use this command. Try " +"SetUserBindHost instead" +msgstr "" + +#: ClientCommand.cpp:1260 +msgid "Usage: SetBindHost " +msgstr "" + +#: ClientCommand.cpp:1265 ClientCommand.cpp:1282 +msgid "You already have this bind host!" +msgstr "" + +#: ClientCommand.cpp:1270 +msgid "Set bind host for network {1} to {2}" +msgstr "" + +#: ClientCommand.cpp:1277 +msgid "Usage: SetUserBindHost " +msgstr "" + +#: ClientCommand.cpp:1287 +msgid "Set default bind host to {1}" +msgstr "" + +#: ClientCommand.cpp:1293 +msgid "" +"You must be connected with a network to use this command. Try " +"ClearUserBindHost instead" +msgstr "" + +#: ClientCommand.cpp:1298 +msgid "Bind host cleared for this network." +msgstr "" + +#: ClientCommand.cpp:1302 +msgid "Default bind host cleared for your user." +msgstr "" + +#: ClientCommand.cpp:1305 +msgid "This user's default bind host not set" +msgstr "" + +#: ClientCommand.cpp:1307 +msgid "This user's default bind host is {1}" +msgstr "" + +#: ClientCommand.cpp:1312 +msgid "This network's bind host not set" +msgstr "" + +#: ClientCommand.cpp:1314 +msgid "This network's default bind host is {1}" +msgstr "" + +#: ClientCommand.cpp:1328 +msgid "Usage: PlayBuffer <#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1336 +msgid "You are not on {1}" +msgstr "" + +#: ClientCommand.cpp:1341 +msgid "You are not on {1} (trying to join)" +msgstr "" + +#: ClientCommand.cpp:1346 +msgid "The buffer for channel {1} is empty" +msgstr "" + +#: ClientCommand.cpp:1355 +msgid "No active query with {1}" +msgstr "" + +#: ClientCommand.cpp:1360 +msgid "The buffer for {1} is empty" +msgstr "" + +#: ClientCommand.cpp:1376 +msgid "Usage: ClearBuffer <#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1395 +msgid "{1} buffer matching {2} has been cleared" +msgid_plural "{1} buffers matching {2} have been cleared" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:1408 +msgid "All channel buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1417 +msgid "All query buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1429 +msgid "All buffers have been cleared" +msgstr "" + +#: ClientCommand.cpp:1440 +msgid "Usage: SetBuffer <#chan|query> [linecount]" +msgstr "" + +#: ClientCommand.cpp:1461 +msgid "Setting buffer size failed for {1} buffer" +msgid_plural "Setting buffer size failed for {1} buffers" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:1464 +msgid "Maximum buffer size is {1} line" +msgid_plural "Maximum buffer size is {1} lines" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:1469 +msgid "Size of every buffer was set to {1} line" +msgid_plural "Size of every buffer was set to {1} lines" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: ClientCommand.cpp:1479 ClientCommand.cpp:1486 ClientCommand.cpp:1497 +#: ClientCommand.cpp:1506 ClientCommand.cpp:1514 +msgctxt "trafficcmd" +msgid "Username" +msgstr "" + +#: ClientCommand.cpp:1480 ClientCommand.cpp:1487 ClientCommand.cpp:1499 +#: ClientCommand.cpp:1508 ClientCommand.cpp:1516 +msgctxt "trafficcmd" +msgid "In" +msgstr "" + +#: ClientCommand.cpp:1481 ClientCommand.cpp:1489 ClientCommand.cpp:1500 +#: ClientCommand.cpp:1509 ClientCommand.cpp:1517 +msgctxt "trafficcmd" +msgid "Out" +msgstr "" + +#: ClientCommand.cpp:1482 ClientCommand.cpp:1492 ClientCommand.cpp:1502 +#: ClientCommand.cpp:1510 ClientCommand.cpp:1519 +msgctxt "trafficcmd" +msgid "Total" +msgstr "" + +#: ClientCommand.cpp:1498 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1507 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1515 +msgctxt "trafficcmd" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1524 +msgid "Running for {1}" +msgstr "" + +#: ClientCommand.cpp:1530 +msgid "Unknown command, try 'Help'" +msgstr "" + +#: ClientCommand.cpp:1539 ClientCommand.cpp:1550 +msgctxt "listports" +msgid "Port" +msgstr "" + +#: ClientCommand.cpp:1540 ClientCommand.cpp:1551 +msgctxt "listports" +msgid "BindHost" +msgstr "" + +#: ClientCommand.cpp:1541 ClientCommand.cpp:1554 +msgctxt "listports" +msgid "SSL" +msgstr "" + +#: ClientCommand.cpp:1542 ClientCommand.cpp:1559 +msgctxt "listports" +msgid "Protocol" +msgstr "" + +#: ClientCommand.cpp:1543 ClientCommand.cpp:1566 +msgctxt "listports" +msgid "IRC" +msgstr "" + +#: ClientCommand.cpp:1544 ClientCommand.cpp:1571 +msgctxt "listports" +msgid "Web" +msgstr "" + +#: ClientCommand.cpp:1555 +msgctxt "listports|ssl" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:1556 +msgctxt "listports|ssl" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1560 +msgctxt "listports" +msgid "IPv4 and IPv6" +msgstr "" + +#: ClientCommand.cpp:1562 +msgctxt "listports" +msgid "IPv4" +msgstr "" + +#: ClientCommand.cpp:1563 +msgctxt "listports" +msgid "IPv6" +msgstr "" + +#: ClientCommand.cpp:1569 +msgctxt "listports|irc" +msgid "yes" +msgstr "" + +#: ClientCommand.cpp:1570 +msgctxt "listports|irc" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1574 +msgctxt "listports|irc" +msgid "yes, on {1}" +msgstr "" + +#: ClientCommand.cpp:1576 +msgctxt "listports|web" +msgid "no" +msgstr "" + +#: ClientCommand.cpp:1616 +msgid "" +"Usage: AddPort <[+]port> [bindhost [uriprefix]]" +msgstr "" + +#: ClientCommand.cpp:1629 +msgid "Unable to bind: {1}" +msgstr "" + +#: ClientCommand.cpp:1632 +msgid "Port added" +msgstr "" + +#: ClientCommand.cpp:1634 +msgid "Couldn't add port" +msgstr "" + +#: ClientCommand.cpp:1640 +msgid "Usage: DelPort [bindhost]" +msgstr "" + +#: ClientCommand.cpp:1649 +msgid "Deleted Port" +msgstr "" + +#: ClientCommand.cpp:1651 +msgid "Unable to find a matching port" +msgstr "" From 1665c8640a0015debe845b7f82978fddbdc6e6f9 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 26 Mar 2018 08:47:27 +0100 Subject: [PATCH 06/20] Fix plurals in some /znc commands (#1354) --- src/ClientCommand.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ClientCommand.cpp b/src/ClientCommand.cpp index 5c9d6384..b41d4663 100644 --- a/src/ClientCommand.cpp +++ b/src/ClientCommand.cpp @@ -129,7 +129,7 @@ void CClient::UserCommand(CString& sLine) { PutStatus(t_p("There was {1} channel matching [{2}]", "There were {1} channels matching [{2}]", sChans.size())(sChans.size(), sPatterns)); - PutStatus(t_p("Attached {1} channel", "Attached {2} channels", + PutStatus(t_p("Attached {1} channel", "Attached {1} channels", uAttachedChans)(uAttachedChans)); } else if (sCommand.Equals("DETACH")) { if (!m_pNetwork) { @@ -151,7 +151,7 @@ void CClient::UserCommand(CString& sLine) { PutStatus(t_p("There was {1} channel matching [{2}]", "There were {1} channels matching [{2}]", sChans.size())(sChans.size(), sPatterns)); - PutStatus(t_p("Detached {1} channel", "Detached {2} channels", + PutStatus(t_p("Detached {1} channel", "Detached {1} channels", uDetached)(uDetached)); } else if (sCommand.Equals("VERSION")) { PutStatus(CZNC::GetTag()); From 5b3d2c1c19b0ddc41f3c5922eef9e0adfa81f2e1 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 26 Mar 2018 21:05:29 +0100 Subject: [PATCH 07/20] More translateable strings (#1354) --- src/ClientCommand.cpp | 345 ++++++++++++++++++++++++------------------ 1 file changed, 201 insertions(+), 144 deletions(-) diff --git a/src/ClientCommand.cpp b/src/ClientCommand.cpp index b41d4663..44bcc324 100644 --- a/src/ClientCommand.cpp +++ b/src/ClientCommand.cpp @@ -1654,187 +1654,244 @@ void CClient::UserPortCommand(CString& sLine) { } } -static void AddCommandHelp(CTable& Table, const CString& sCmd, - const CString& sArgs, const CString& sDesc, - const CString& sFilter = "") { - if (sFilter.empty() || sCmd.StartsWith(sFilter) || - sCmd.AsLower().WildCmp(sFilter.AsLower())) { - Table.AddRow(); - Table.SetCell("Command", sCmd + " " + sArgs); - Table.SetCell("Description", sDesc); - } -} - void CClient::HelpUser(const CString& sFilter) { CTable Table; - Table.AddColumn("Command"); - Table.AddColumn("Description"); + Table.AddColumn(t_s("Command", "helpcmd")); + Table.AddColumn(t_s("Description", "helpcmd")); if (sFilter.empty()) { PutStatus( - "In the following list all occurrences of <#chan> support " - "wildcards (* and ?)"); - PutStatus("(Except ListNicks)"); + t_s("In the following list all occurrences of <#chan> support " + "wildcards (* and ?) except ListNicks")); } - AddCommandHelp(Table, "Version", "", "Print which version of ZNC this is", - sFilter); + const auto AddCommandHelp = [&](const CString& sCmd, const CString& sArgs, + const CString& sDesc) { + if (sFilter.empty() || sCmd.StartsWith(sFilter) || + sCmd.AsLower().WildCmp(sFilter.AsLower())) { + Table.AddRow(); + Table.SetCell(t_s("Command", "helpcmd"), sCmd + " " + sArgs); + Table.SetCell(t_s("Description", "helpcmd"), sDesc); + } + }; - AddCommandHelp(Table, "ListMods", "", "List all loaded modules", sFilter); - AddCommandHelp(Table, "ListAvailMods", "", "List all available modules", - sFilter); + AddCommandHelp( + "Version", "", + t_s("Print which version of ZNC this is", "helpcmd|Version|desc")); + + AddCommandHelp("ListMods", "", + t_s("List all loaded modules", "helpcmd|ListMods|desc")); + AddCommandHelp( + "ListAvailMods", "", + t_s("List all available modules", "helpcmd|ListAvailMods|desc")); if (!m_pUser->IsAdmin()) { // If they are an admin we will add this command below with an argument - AddCommandHelp(Table, "ListChans", "", "List all channels", sFilter); + AddCommandHelp("ListChans", "", + t_s("List all channels", "helpcmd|ListChans|desc")); } - AddCommandHelp(Table, "ListNicks", "<#chan>", "List all nicks on a channel", - sFilter); + AddCommandHelp( + "ListNicks", t_s("<#chan>", "helpcmd|ListNicks|args"), + t_s("List all nicks on a channel", "helpcmd|ListNicks|desc")); if (!m_pUser->IsAdmin()) { - AddCommandHelp(Table, "ListClients", "", - "List all clients connected to your ZNC user", sFilter); + AddCommandHelp("ListClients", "", + t_s("List all clients connected to your ZNC user", + "helpcmd|ListClients|desc")); } - AddCommandHelp(Table, "ListServers", "", - "List all servers of current IRC network", sFilter); + AddCommandHelp("ListServers", "", + t_s("List all servers of current IRC network", + "helpcmd|ListServers|desc")); - AddCommandHelp(Table, "AddNetwork", "", "Add a network to your user", - sFilter); - AddCommandHelp(Table, "DelNetwork", "", - "Delete a network from your user", sFilter); - AddCommandHelp(Table, "ListNetworks", "", "List all networks", sFilter); + AddCommandHelp( + "AddNetwork", t_s("", "helpcmd|AddNetwork|args"), + t_s("Add a network to your user", "helpcmd|AddNetwork|desc")); + AddCommandHelp( + "DelNetwork", t_s("", "helpcmd|DelNetwork|args"), + t_s("Delete a network from your user", "helpcmd|DelNetwork|desc")); + AddCommandHelp("ListNetworks", "", + t_s("List all networks", "helpcmd|ListNetworks|desc")); if (m_pUser->IsAdmin()) { - AddCommandHelp(Table, "MoveNetwork", - " [new network]", - "Move an IRC network from one user to another", sFilter); + AddCommandHelp("MoveNetwork", + t_s(" [new network]", + "helpcmd|MoveNetwork|args"), + t_s("Move an IRC network from one user to another", + "helpcmd|MoveNetwork|desc")); } - AddCommandHelp(Table, "JumpNetwork", "", - "Jump to another network (Alternatively, you can connect to " - "ZNC several times, using `user/network` as username)", - sFilter); - - AddCommandHelp(Table, "AddServer", " [[+]port] [pass]", - "Add a server to the list of alternate/backup servers of " - "current IRC network.", - sFilter); - AddCommandHelp(Table, "DelServer", " [port] [pass]", - "Remove a server from the list of alternate/backup servers " - "of current IRC network", - sFilter); - - AddCommandHelp(Table, "AddTrustedServerFingerprint", "", - "Add a trusted server SSL certificate fingerprint (SHA-256) " - "to current IRC network.", - sFilter); AddCommandHelp( - Table, "DelTrustedServerFingerprint", "", - "Delete a trusted server SSL certificate from current IRC network.", - sFilter); + "JumpNetwork", t_s("", "helpcmd|JumpNetwork|args"), + t_s("Jump to another network (Alternatively, you can connect to ZNC " + "several times, using `user/network` as username)", + "helpcmd|JumpNetwork|desc")); + + AddCommandHelp("AddServer", + t_s(" [[+]port] [pass]", "helpcmd|AddServer|args"), + t_s("Add a server to the list of alternate/backup servers " + "of current IRC network.", + "helpcmd|AddServer|desc")); + AddCommandHelp("DelServer", + t_s(" [port] [pass]", "helpcmd|DelServer|args"), + t_s("Remove a server from the list of alternate/backup " + "servers of current IRC network", + "helpcmd|DelServer|desc")); + AddCommandHelp( - Table, "ListTrustedServerFingerprints", "", - "List all trusted server SSL certificates of current IRC network.", - sFilter); + "AddTrustedServerFingerprint", + t_s("", "helpcmd|AddTrustedServerFingerprint|args"), + t_s("Add a trusted server SSL certificate fingerprint (SHA-256) to " + "current IRC network.", + "helpcmd|AddTrustedServerFingerprint|desc")); + AddCommandHelp( + "DelTrustedServerFingerprint", + t_s("", "helpcmd|DelTrustedServerFingerprint|args"), + t_s("Delete a trusted server SSL certificate from current IRC network.", + "helpcmd|DelTrustedServerFingerprint|desc")); + AddCommandHelp( + "ListTrustedServerFingerprints", "", + t_s("List all trusted server SSL certificates of current IRC network.", + "helpcmd|ListTrustedServerFingerprints|desc")); - AddCommandHelp(Table, "EnableChan", "<#chans>", "Enable channels", sFilter); - AddCommandHelp(Table, "DisableChan", "<#chans>", "Disable channels", - sFilter); - AddCommandHelp(Table, "Attach", "<#chans>", "Attach to channels", sFilter); - AddCommandHelp(Table, "Detach", "<#chans>", "Detach from channels", - sFilter); - AddCommandHelp(Table, "Topics", "", "Show topics in all your channels", - sFilter); + AddCommandHelp("EnableChan", t_s("<#chans>", "helpcmd|EnableChan|args"), + t_s("Enable channels", "helpcmd|EnableChan|desc")); + AddCommandHelp("DisableChan", t_s("<#chans>", "helpcmd|DisableChan|args"), + t_s("Disable channels", "helpcmd|DisableChan|desc")); + AddCommandHelp("Attach", t_s("<#chans>", "helpcmd|Attach|args"), + t_s("Attach to channels", "helpcmd|Attach|desc")); + AddCommandHelp("Detach", t_s("<#chans>", "helpcmd|Detach|args"), + t_s("Detach from channels", "helpcmd|Detach|desc")); + AddCommandHelp( + "Topics", "", + t_s("Show topics in all your channels", "helpcmd|Topics|desc")); - AddCommandHelp(Table, "PlayBuffer", "<#chan|query>", - "Play back the specified buffer", sFilter); - AddCommandHelp(Table, "ClearBuffer", "<#chan|query>", - "Clear the specified buffer", sFilter); - AddCommandHelp(Table, "ClearAllBuffers", "", - "Clear all channel and query buffers", sFilter); - AddCommandHelp(Table, "ClearAllChannelBuffers", "", - "Clear the channel buffers", sFilter); - AddCommandHelp(Table, "ClearAllQueryBuffers", "", "Clear the query buffers", - sFilter); - AddCommandHelp(Table, "SetBuffer", "<#chan|query> [linecount]", - "Set the buffer count", sFilter); + AddCommandHelp( + "PlayBuffer", t_s("<#chan|query>", "helpcmd|PlayBuffer|args"), + t_s("Play back the specified buffer", "helpcmd|PlayBuffer|desc")); + AddCommandHelp( + "ClearBuffer", t_s("<#chan|query>", "helpcmd|ClearBuffer|args"), + t_s("Clear the specified buffer", "helpcmd|ClearBuffer|desc")); + AddCommandHelp("ClearAllBuffers", "", + t_s("Clear all channel and query buffers", + "helpcmd|ClearAllBuffers|desc")); + AddCommandHelp("ClearAllChannelBuffers", "", + t_s("Clear the channel buffers", + "helpcmd|ClearAllChannelBuffers|desc")); + AddCommandHelp( + "ClearAllQueryBuffers", "", + t_s("Clear the query buffers", "helpcmd|ClearAllQueryBuffers|desc")); + AddCommandHelp("SetBuffer", + t_s("<#chan|query> [linecount]", "helpcmd|SetBuffer|args"), + t_s("Set the buffer count", "helpcmd|SetBuffer|desc")); if (m_pUser->IsAdmin() || !m_pUser->DenySetBindHost()) { - AddCommandHelp(Table, "SetBindHost", "", - "Set the bind host for this connection", sFilter); - AddCommandHelp(Table, "SetUserBindHost", "", - "Set the default bind host for this user", sFilter); - AddCommandHelp(Table, "ClearBindHost", "", - "Clear the bind host for this connection", sFilter); - AddCommandHelp(Table, "ClearUserBindHost", "", - "Clear the default bind host for this user", sFilter); + AddCommandHelp("SetBindHost", + t_s("", "helpcmd|SetBindHost|args"), + t_s("Set the bind host for this network", + "helpcmd|SetBindHost|desc")); + AddCommandHelp( + "SetUserBindHost", + t_s("", "helpcmd|SetUserBindHost|args"), + t_s("Set the default bind host for this user", + "helpcmd|SetUserBindHost|desc")); + AddCommandHelp("ClearBindHost", "", + t_s("Clear the bind host for this network", + "helpcmd|ClearBindHost|desc")); + AddCommandHelp("ClearUserBindHost", "", + t_s("Clear the default bind host for this user", + "helpcmd|ClearUserBindHost|desc")); } - AddCommandHelp(Table, "ShowBindHost", "", - "Show currently selected bind host", sFilter); - AddCommandHelp(Table, "Jump", "[server]", - "Jump to the next or the specified server", sFilter); - AddCommandHelp(Table, "Disconnect", "[message]", "Disconnect from IRC", - sFilter); - AddCommandHelp(Table, "Connect", "", "Reconnect to IRC", sFilter); - AddCommandHelp(Table, "Uptime", "", - "Show for how long ZNC has been running", sFilter); + AddCommandHelp( + "ShowBindHost", "", + t_s("Show currently selected bind host", "helpcmd|ShowBindHost|desc")); + AddCommandHelp( + "Jump", t_s("[server]", "helpcmd|Jump|args"), + t_s("Jump to the next or the specified server", "helpcmd|Jump|desc")); + AddCommandHelp("Disconnect", t_s("[message]", "helpcmd|Disconnect|args"), + t_s("Disconnect from IRC", "helpcmd|Disconnect|desc")); + AddCommandHelp("Connect", "", + t_s("Reconnect to IRC", "helpcmd|Connect|desc")); + AddCommandHelp( + "Uptime", "", + t_s("Show for how long ZNC has been running", "helpcmd|Uptime|desc")); if (!m_pUser->DenyLoadMod()) { - AddCommandHelp(Table, "LoadMod", - "[--type=global|user|network] ", "Load a module", - sFilter); - AddCommandHelp(Table, "UnloadMod", - "[--type=global|user|network] ", - "Unload a module", sFilter); - AddCommandHelp(Table, "ReloadMod", - "[--type=global|user|network] ", - "Reload a module", sFilter); + AddCommandHelp("LoadMod", + t_s("[--type=global|user|network] ", + "helpcmd|LoadMod|args"), + t_s("Load a module", "helpcmd|LoadMod|desc")); + AddCommandHelp("UnloadMod", + t_s("[--type=global|user|network] ", + "helpcmd|UnloadMod|args"), + t_s("Unload a module", "helpcmd|UnloadMod|desc")); + AddCommandHelp("ReloadMod", + t_s("[--type=global|user|network] ", + "helpcmd|ReloadMod|args"), + t_s("Reload a module", "helpcmd|ReloadMod|desc")); if (m_pUser->IsAdmin()) { - AddCommandHelp(Table, "UpdateMod", "", - "Reload a module everywhere", sFilter); + AddCommandHelp( + "UpdateMod", t_s("", "helpcmd|UpdateMod|args"), + t_s("Reload a module everywhere", "helpcmd|UpdateMod|desc")); } } - AddCommandHelp(Table, "ShowMOTD", "", "Show ZNC's message of the day", - sFilter); + AddCommandHelp( + "ShowMOTD", "", + t_s("Show ZNC's message of the day", "helpcmd|ShowMOTD|desc")); if (m_pUser->IsAdmin()) { - AddCommandHelp(Table, "SetMOTD", "", - "Set ZNC's message of the day", sFilter); - AddCommandHelp(Table, "AddMOTD", "", - "Append to ZNC's MOTD", sFilter); - AddCommandHelp(Table, "ClearMOTD", "", "Clear ZNC's MOTD", sFilter); - AddCommandHelp(Table, "ListPorts", "", "Show all active listeners", - sFilter); AddCommandHelp( - Table, "AddPort", - "<[+]port> [bindhost [uriprefix]]", - "Add another port for ZNC to listen on", sFilter); - AddCommandHelp(Table, "DelPort", " [bindhost]", - "Remove a port from ZNC", sFilter); + "SetMOTD", t_s("", "helpcmd|SetMOTD|args"), + t_s("Set ZNC's message of the day", "helpcmd|SetMOTD|desc")); AddCommandHelp( - Table, "Rehash", "", - "Reload global settings, modules, and listeners from znc.conf", - sFilter); - AddCommandHelp(Table, "SaveConfig", "", - "Save the current settings to disk", sFilter); - AddCommandHelp(Table, "ListUsers", "", - "List all ZNC users and their connection status", - sFilter); - AddCommandHelp(Table, "ListAllUserNetworks", "", - "List all ZNC users and their networks", sFilter); - AddCommandHelp(Table, "ListChans", "[user ]", - "List all channels", sFilter); - AddCommandHelp(Table, "ListClients", "[user]", - "List all connected clients", sFilter); - AddCommandHelp(Table, "Traffic", "", - "Show basic traffic stats for all ZNC users", sFilter); - AddCommandHelp(Table, "Broadcast", "[message]", - "Broadcast a message to all ZNC users", sFilter); - AddCommandHelp(Table, "Shutdown", "[message]", - "Shut down ZNC completely", sFilter); - AddCommandHelp(Table, "Restart", "[message]", "Restart ZNC", sFilter); + "AddMOTD", t_s("", "helpcmd|AddMOTD|args"), + t_s("Append to ZNC's MOTD", "helpcmd|AddMOTD|desc")); + AddCommandHelp("ClearMOTD", "", + t_s("Clear ZNC's MOTD", "helpcmd|ClearMOTD|desc")); + AddCommandHelp( + "ListPorts", "", + t_s("Show all active listeners", "helpcmd|ListPorts|desc")); + AddCommandHelp("AddPort", + t_s("<[+]port> [bindhost " + "[uriprefix]]", + "helpcmd|AddPort|args"), + t_s("Add another port for ZNC to listen on", + "helpcmd|AddPort|desc")); + AddCommandHelp( + "DelPort", + t_s(" [bindhost]", "helpcmd|DelPort|args"), + t_s("Remove a port from ZNC", "helpcmd|DelPort|desc")); + AddCommandHelp( + "Rehash", "", + t_s("Reload global settings, modules, and listeners from znc.conf", + "helpcmd|Rehash|desc")); + AddCommandHelp("SaveConfig", "", + t_s("Save the current settings to disk", + "helpcmd|SaveConfig|desc")); + AddCommandHelp("ListUsers", "", + t_s("List all ZNC users and their connection status", + "helpcmd|ListUsers|desc")); + AddCommandHelp("ListAllUserNetworks", "", + t_s("List all ZNC users and their networks", + "helpcmd|ListAllUserNetworks|desc")); + AddCommandHelp("ListChans", + t_s("[user ]", "helpcmd|ListChans|args"), + t_s("List all channels", "helpcmd|ListChans|desc")); + AddCommandHelp( + "ListClients", t_s("[user]", "helpcmd|ListClients|args"), + t_s("List all connected clients", "helpcmd|ListClients|desc")); + AddCommandHelp("Traffic", "", + t_s("Show basic traffic stats for all ZNC users", + "helpcmd|Traffic|desc")); + AddCommandHelp("Broadcast", t_s("[message]", "helpcmd|Broadcast|args"), + t_s("Broadcast a message to all ZNC users", + "helpcmd|Broadcast|desc")); + AddCommandHelp( + "Shutdown", t_s("[message]", "helpcmd|Shutdown|args"), + t_s("Shut down ZNC completely", "helpcmd|Shutdown|desc")); + AddCommandHelp("Restart", t_s("[message]", "helpcmd|Restart|args"), + t_s("Restart ZNC", "helpcmd|Restart|desc")); } if (Table.empty()) { - PutStatus("No matches for '" + sFilter + "'"); + PutStatus(t_f("No matches for '{1}'")(sFilter)); } else { PutStatus(Table); } From 6eaa93f8dac1f0b2265f8ef134d5804c43d1e47e Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Tue, 27 Mar 2018 22:22:56 +0100 Subject: [PATCH 08/20] Fix python sockets after latest changes. The issue was triggered by CCoreTranslationMixin being parent of CZNCSock, and DisableReadLine wasn't found as attribute anymore. Thanks to obiw4n for report. --- modules/modpython/znc.py | 5 ++-- test/integration/tests/scripting.cpp | 42 ++++++++++++++++++++++++++++ 2 files changed, 45 insertions(+), 2 deletions(-) diff --git a/modules/modpython/znc.py b/modules/modpython/znc.py index ad77db6b..45430cbe 100644 --- a/modules/modpython/znc.py +++ b/modules/modpython/znc.py @@ -676,8 +676,9 @@ def make_inherit(cl, parent, attr): for x in parent.__dict__: if not x.startswith('_') and x not in cl.__dict__: setattr(cl, x, make_caller(parent, x, attr)) - if '_s' in parent.__dict__: - parent = parent._s + if parent.__bases__: + # Multiple inheritance is not supported (yet?) + parent = parent.__bases__[0] else: break diff --git a/test/integration/tests/scripting.cpp b/test/integration/tests/scripting.cpp index 2d9836bd..ebb4dba2 100644 --- a/test/integration/tests/scripting.cpp +++ b/test/integration/tests/scripting.cpp @@ -57,5 +57,47 @@ TEST_F(ZNCTest, Modpython) { client.ReadUntil("Hi\xEF\xBF\xBD, github issue"); } +TEST_F(ZNCTest, ModpythonSocket) { + if (QProcessEnvironment::systemEnvironment().value( + "DISABLED_ZNC_PERL_PYTHON_TEST") == "1") { + return; + } + auto znc = Run(); + znc->CanLeak(); + + InstallModule("socktest.py", R"( + import znc + + class acc(znc.Socket): + def OnReadData(self, data): + self.GetModule().PutModule('received {} bytes'.format(len(data))) + self.Close() + + class lis(znc.Socket): + def OnAccepted(self, host, port): + sock = self.GetModule().CreateSocket(acc) + sock.DisableReadLine() + return sock + + class socktest(znc.Module): + def OnLoad(self, args, ret): + listen = self.CreateSocket(lis) + self.port = listen.Listen() + return True + + def OnModCommand(self, cmd): + sock = self.CreateSocket() + sock.Connect('127.0.0.1', self.port) + sock.WriteBytes(b'blah') + )"); + + auto ircd = ConnectIRCd(); + auto client = LoginClient(); + client.Write("znc loadmod modpython"); + client.Write("znc loadmod socktest"); + client.Write("PRIVMSG *socktest :foo"); + client.ReadUntil("received 4 bytes"); +} + } // namespace } // namespace znc_inttest From d8327977ca50b49d275fa322e0cc0adfa9ec1933 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Tue, 27 Mar 2018 22:49:23 +0100 Subject: [PATCH 09/20] Add socket test to modperl --- test/integration/tests/scripting.cpp | 53 ++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/test/integration/tests/scripting.cpp b/test/integration/tests/scripting.cpp index ebb4dba2..213d15a4 100644 --- a/test/integration/tests/scripting.cpp +++ b/test/integration/tests/scripting.cpp @@ -99,5 +99,58 @@ TEST_F(ZNCTest, ModpythonSocket) { client.ReadUntil("received 4 bytes"); } +TEST_F(ZNCTest, ModperlSocket) { + if (QProcessEnvironment::systemEnvironment().value( + "DISABLED_ZNC_PERL_PYTHON_TEST") == "1") { + return; + } + auto znc = Run(); + znc->CanLeak(); + + InstallModule("socktest.pm", R"( + package socktest::acc; + use base 'ZNC::Socket'; + sub OnReadData { + my ($self, $data, $len) = @_; + $self->GetModule->PutModule("received $len bytes"); + $self->Close; + } + + package socktest::lis; + use base 'ZNC::Socket'; + sub OnAccepted { + my $self = shift; + return $self->GetModule->CreateSocket('socktest::acc'); + } + + package socktest::conn; + use base 'ZNC::Socket'; + + package socktest; + use base 'ZNC::Module'; + sub OnLoad { + my $self = shift; + my $listen = $self->CreateSocket('socktest::lis'); + $self->{port} = $listen->Listen; + return 1; + } + sub OnModCommand { + my ($self, $cmd) = @_; + my $sock = $self->CreateSocket('socktest::conn'); + $sock->Connect('127.0.0.1', $self->{port}); + $sock->Write('blah'); + } + + 1; + )"); + + auto ircd = ConnectIRCd(); + auto client = LoginClient(); + client.Write("znc loadmod modperl"); + client.Write("znc loadmod socktest"); + client.Write("PRIVMSG *socktest :foo"); + client.ReadUntil("received 4 bytes"); +} + } // namespace } // namespace znc_inttest From 82a932537575fe667c9e61fe07b6586d2132bbe2 Mon Sep 17 00:00:00 2001 From: ZNC-Jenkins bot Date: Tue, 27 Mar 2018 23:30:28 +0100 Subject: [PATCH 10/20] Update translations from Crowdin (#1500) --- src/po/znc.de.po | 481 ++++++++++++++++++++++++++++++++++++++++++++++- src/po/znc.pot | 481 ++++++++++++++++++++++++++++++++++++++++++++++- src/po/znc.ru.po | 481 ++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 1437 insertions(+), 6 deletions(-) diff --git a/src/po/znc.de.po b/src/po/znc.de.po index c3fbe3c7..c88f3cd4 100644 --- a/src/po/znc.de.po +++ b/src/po/znc.de.po @@ -113,7 +113,7 @@ msgstr[1] "" #: ClientCommand.cpp:132 msgid "Attached {1} channel" -msgid_plural "Attached {2} channels" +msgid_plural "Attached {1} channels" msgstr[0] "" msgstr[1] "" @@ -123,7 +123,7 @@ msgstr "" #: ClientCommand.cpp:154 msgid "Detached {1} channel" -msgid_plural "Detached {2} channels" +msgid_plural "Detached {1} channels" msgstr[0] "" msgstr[1] "" @@ -884,3 +884,480 @@ msgstr "" #: ClientCommand.cpp:1651 msgid "Unable to find a matching port" msgstr "" + +#: ClientCommand.cpp:1659 ClientCommand.cpp:1673 +msgctxt "helpcmd" +msgid "Command" +msgstr "" + +#: ClientCommand.cpp:1660 ClientCommand.cpp:1674 +msgctxt "helpcmd" +msgid "Description" +msgstr "" + +#: ClientCommand.cpp:1664 +msgid "" +"In the following list all occurrences of <#chan> support wildcards (* and ?) " +"except ListNicks" +msgstr "" + +#: ClientCommand.cpp:1680 +msgctxt "helpcmd|Version|desc" +msgid "Print which version of ZNC this is" +msgstr "" + +#: ClientCommand.cpp:1683 +msgctxt "helpcmd|ListMods|desc" +msgid "List all loaded modules" +msgstr "" + +#: ClientCommand.cpp:1686 +msgctxt "helpcmd|ListAvailMods|desc" +msgid "List all available modules" +msgstr "" + +#: ClientCommand.cpp:1690 ClientCommand.cpp:1876 +msgctxt "helpcmd|ListChans|desc" +msgid "List all channels" +msgstr "" + +#: ClientCommand.cpp:1693 +msgctxt "helpcmd|ListNicks|args" +msgid "<#chan>" +msgstr "" + +#: ClientCommand.cpp:1694 +msgctxt "helpcmd|ListNicks|desc" +msgid "List all nicks on a channel" +msgstr "" + +#: ClientCommand.cpp:1697 +msgctxt "helpcmd|ListClients|desc" +msgid "List all clients connected to your ZNC user" +msgstr "" + +#: ClientCommand.cpp:1701 +msgctxt "helpcmd|ListServers|desc" +msgid "List all servers of current IRC network" +msgstr "" + +#: ClientCommand.cpp:1705 +msgctxt "helpcmd|AddNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1706 +msgctxt "helpcmd|AddNetwork|desc" +msgid "Add a network to your user" +msgstr "" + +#: ClientCommand.cpp:1708 +msgctxt "helpcmd|DelNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1709 +msgctxt "helpcmd|DelNetwork|desc" +msgid "Delete a network from your user" +msgstr "" + +#: ClientCommand.cpp:1711 +msgctxt "helpcmd|ListNetworks|desc" +msgid "List all networks" +msgstr "" + +#: ClientCommand.cpp:1714 +msgctxt "helpcmd|MoveNetwork|args" +msgid " [new network]" +msgstr "" + +#: ClientCommand.cpp:1716 +msgctxt "helpcmd|MoveNetwork|desc" +msgid "Move an IRC network from one user to another" +msgstr "" + +#: ClientCommand.cpp:1720 +msgctxt "helpcmd|JumpNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1721 +msgctxt "helpcmd|JumpNetwork|desc" +msgid "" +"Jump to another network (Alternatively, you can connect to ZNC several " +"times, using `user/network` as username)" +msgstr "" + +#: ClientCommand.cpp:1726 +msgctxt "helpcmd|AddServer|args" +msgid " [[+]port] [pass]" +msgstr "" + +#: ClientCommand.cpp:1727 +msgctxt "helpcmd|AddServer|desc" +msgid "" +"Add a server to the list of alternate/backup servers of current IRC network." +msgstr "" + +#: ClientCommand.cpp:1731 +msgctxt "helpcmd|DelServer|args" +msgid " [port] [pass]" +msgstr "" + +#: ClientCommand.cpp:1732 +msgctxt "helpcmd|DelServer|desc" +msgid "" +"Remove a server from the list of alternate/backup servers of current IRC " +"network" +msgstr "" + +#: ClientCommand.cpp:1738 +msgctxt "helpcmd|AddTrustedServerFingerprint|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1739 +msgctxt "helpcmd|AddTrustedServerFingerprint|desc" +msgid "" +"Add a trusted server SSL certificate fingerprint (SHA-256) to current IRC " +"network." +msgstr "" + +#: ClientCommand.cpp:1744 +msgctxt "helpcmd|DelTrustedServerFingerprint|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1745 +msgctxt "helpcmd|DelTrustedServerFingerprint|desc" +msgid "Delete a trusted server SSL certificate from current IRC network." +msgstr "" + +#: ClientCommand.cpp:1749 +msgctxt "helpcmd|ListTrustedServerFingerprints|desc" +msgid "List all trusted server SSL certificates of current IRC network." +msgstr "" + +#: ClientCommand.cpp:1752 +msgctxt "helpcmd|EnableChan|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1753 +msgctxt "helpcmd|EnableChan|desc" +msgid "Enable channels" +msgstr "" + +#: ClientCommand.cpp:1754 +msgctxt "helpcmd|DisableChan|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1755 +msgctxt "helpcmd|DisableChan|desc" +msgid "Disable channels" +msgstr "" + +#: ClientCommand.cpp:1756 +msgctxt "helpcmd|Attach|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1757 +msgctxt "helpcmd|Attach|desc" +msgid "Attach to channels" +msgstr "" + +#: ClientCommand.cpp:1758 +msgctxt "helpcmd|Detach|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1759 +msgctxt "helpcmd|Detach|desc" +msgid "Detach from channels" +msgstr "" + +#: ClientCommand.cpp:1762 +msgctxt "helpcmd|Topics|desc" +msgid "Show topics in all your channels" +msgstr "" + +#: ClientCommand.cpp:1765 +msgctxt "helpcmd|PlayBuffer|args" +msgid "<#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1766 +msgctxt "helpcmd|PlayBuffer|desc" +msgid "Play back the specified buffer" +msgstr "" + +#: ClientCommand.cpp:1768 +msgctxt "helpcmd|ClearBuffer|args" +msgid "<#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1769 +msgctxt "helpcmd|ClearBuffer|desc" +msgid "Clear the specified buffer" +msgstr "" + +#: ClientCommand.cpp:1771 +msgctxt "helpcmd|ClearAllBuffers|desc" +msgid "Clear all channel and query buffers" +msgstr "" + +#: ClientCommand.cpp:1774 +msgctxt "helpcmd|ClearAllChannelBuffers|desc" +msgid "Clear the channel buffers" +msgstr "" + +#: ClientCommand.cpp:1778 +msgctxt "helpcmd|ClearAllQueryBuffers|desc" +msgid "Clear the query buffers" +msgstr "" + +#: ClientCommand.cpp:1780 +msgctxt "helpcmd|SetBuffer|args" +msgid "<#chan|query> [linecount]" +msgstr "" + +#: ClientCommand.cpp:1781 +msgctxt "helpcmd|SetBuffer|desc" +msgid "Set the buffer count" +msgstr "" + +#: ClientCommand.cpp:1785 +msgctxt "helpcmd|SetBindHost|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1786 +msgctxt "helpcmd|SetBindHost|desc" +msgid "Set the bind host for this network" +msgstr "" + +#: ClientCommand.cpp:1790 +msgctxt "helpcmd|SetUserBindHost|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1791 +msgctxt "helpcmd|SetUserBindHost|desc" +msgid "Set the default bind host for this user" +msgstr "" + +#: ClientCommand.cpp:1794 +msgctxt "helpcmd|ClearBindHost|desc" +msgid "Clear the bind host for this network" +msgstr "" + +#: ClientCommand.cpp:1797 +msgctxt "helpcmd|ClearUserBindHost|desc" +msgid "Clear the default bind host for this user" +msgstr "" + +#: ClientCommand.cpp:1803 +msgctxt "helpcmd|ShowBindHost|desc" +msgid "Show currently selected bind host" +msgstr "" + +#: ClientCommand.cpp:1805 +msgctxt "helpcmd|Jump|args" +msgid "[server]" +msgstr "" + +#: ClientCommand.cpp:1806 +msgctxt "helpcmd|Jump|desc" +msgid "Jump to the next or the specified server" +msgstr "" + +#: ClientCommand.cpp:1807 +msgctxt "helpcmd|Disconnect|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1808 +msgctxt "helpcmd|Disconnect|desc" +msgid "Disconnect from IRC" +msgstr "" + +#: ClientCommand.cpp:1810 +msgctxt "helpcmd|Connect|desc" +msgid "Reconnect to IRC" +msgstr "" + +#: ClientCommand.cpp:1813 +msgctxt "helpcmd|Uptime|desc" +msgid "Show for how long ZNC has been running" +msgstr "" + +#: ClientCommand.cpp:1817 +msgctxt "helpcmd|LoadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1819 +msgctxt "helpcmd|LoadMod|desc" +msgid "Load a module" +msgstr "" + +#: ClientCommand.cpp:1821 +msgctxt "helpcmd|UnloadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1823 +msgctxt "helpcmd|UnloadMod|desc" +msgid "Unload a module" +msgstr "" + +#: ClientCommand.cpp:1825 +msgctxt "helpcmd|ReloadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1827 +msgctxt "helpcmd|ReloadMod|desc" +msgid "Reload a module" +msgstr "" + +#: ClientCommand.cpp:1830 +msgctxt "helpcmd|UpdateMod|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1831 +msgctxt "helpcmd|UpdateMod|desc" +msgid "Reload a module everywhere" +msgstr "" + +#: ClientCommand.cpp:1837 +msgctxt "helpcmd|ShowMOTD|desc" +msgid "Show ZNC's message of the day" +msgstr "" + +#: ClientCommand.cpp:1841 +msgctxt "helpcmd|SetMOTD|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1842 +msgctxt "helpcmd|SetMOTD|desc" +msgid "Set ZNC's message of the day" +msgstr "" + +#: ClientCommand.cpp:1844 +msgctxt "helpcmd|AddMOTD|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1845 +msgctxt "helpcmd|AddMOTD|desc" +msgid "Append to ZNC's MOTD" +msgstr "" + +#: ClientCommand.cpp:1847 +msgctxt "helpcmd|ClearMOTD|desc" +msgid "Clear ZNC's MOTD" +msgstr "" + +#: ClientCommand.cpp:1850 +msgctxt "helpcmd|ListPorts|desc" +msgid "Show all active listeners" +msgstr "" + +#: ClientCommand.cpp:1852 +msgctxt "helpcmd|AddPort|args" +msgid "<[+]port> [bindhost [uriprefix]]" +msgstr "" + +#: ClientCommand.cpp:1855 +msgctxt "helpcmd|AddPort|desc" +msgid "Add another port for ZNC to listen on" +msgstr "" + +#: ClientCommand.cpp:1859 +msgctxt "helpcmd|DelPort|args" +msgid " [bindhost]" +msgstr "" + +#: ClientCommand.cpp:1860 +msgctxt "helpcmd|DelPort|desc" +msgid "Remove a port from ZNC" +msgstr "" + +#: ClientCommand.cpp:1863 +msgctxt "helpcmd|Rehash|desc" +msgid "Reload global settings, modules, and listeners from znc.conf" +msgstr "" + +#: ClientCommand.cpp:1866 +msgctxt "helpcmd|SaveConfig|desc" +msgid "Save the current settings to disk" +msgstr "" + +#: ClientCommand.cpp:1869 +msgctxt "helpcmd|ListUsers|desc" +msgid "List all ZNC users and their connection status" +msgstr "" + +#: ClientCommand.cpp:1872 +msgctxt "helpcmd|ListAllUserNetworks|desc" +msgid "List all ZNC users and their networks" +msgstr "" + +#: ClientCommand.cpp:1875 +msgctxt "helpcmd|ListChans|args" +msgid "[user ]" +msgstr "" + +#: ClientCommand.cpp:1878 +msgctxt "helpcmd|ListClients|args" +msgid "[user]" +msgstr "" + +#: ClientCommand.cpp:1879 +msgctxt "helpcmd|ListClients|desc" +msgid "List all connected clients" +msgstr "" + +#: ClientCommand.cpp:1881 +msgctxt "helpcmd|Traffic|desc" +msgid "Show basic traffic stats for all ZNC users" +msgstr "" + +#: ClientCommand.cpp:1883 +msgctxt "helpcmd|Broadcast|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1884 +msgctxt "helpcmd|Broadcast|desc" +msgid "Broadcast a message to all ZNC users" +msgstr "" + +#: ClientCommand.cpp:1887 +msgctxt "helpcmd|Shutdown|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1888 +msgctxt "helpcmd|Shutdown|desc" +msgid "Shut down ZNC completely" +msgstr "" + +#: ClientCommand.cpp:1889 +msgctxt "helpcmd|Restart|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1890 +msgctxt "helpcmd|Restart|desc" +msgid "Restart ZNC" +msgstr "" + +#: ClientCommand.cpp:1894 +msgid "No matches for '{1}'" +msgstr "" diff --git a/src/po/znc.pot b/src/po/znc.pot index 8197f9cf..6b19d067 100644 --- a/src/po/znc.pot +++ b/src/po/znc.pot @@ -99,7 +99,7 @@ msgstr[1] "" #: ClientCommand.cpp:132 msgid "Attached {1} channel" -msgid_plural "Attached {2} channels" +msgid_plural "Attached {1} channels" msgstr[0] "" msgstr[1] "" @@ -109,7 +109,7 @@ msgstr "" #: ClientCommand.cpp:154 msgid "Detached {1} channel" -msgid_plural "Detached {2} channels" +msgid_plural "Detached {1} channels" msgstr[0] "" msgstr[1] "" @@ -870,3 +870,480 @@ msgstr "" #: ClientCommand.cpp:1651 msgid "Unable to find a matching port" msgstr "" + +#: ClientCommand.cpp:1659 ClientCommand.cpp:1673 +msgctxt "helpcmd" +msgid "Command" +msgstr "" + +#: ClientCommand.cpp:1660 ClientCommand.cpp:1674 +msgctxt "helpcmd" +msgid "Description" +msgstr "" + +#: ClientCommand.cpp:1664 +msgid "" +"In the following list all occurrences of <#chan> support wildcards (* and ?) " +"except ListNicks" +msgstr "" + +#: ClientCommand.cpp:1680 +msgctxt "helpcmd|Version|desc" +msgid "Print which version of ZNC this is" +msgstr "" + +#: ClientCommand.cpp:1683 +msgctxt "helpcmd|ListMods|desc" +msgid "List all loaded modules" +msgstr "" + +#: ClientCommand.cpp:1686 +msgctxt "helpcmd|ListAvailMods|desc" +msgid "List all available modules" +msgstr "" + +#: ClientCommand.cpp:1690 ClientCommand.cpp:1876 +msgctxt "helpcmd|ListChans|desc" +msgid "List all channels" +msgstr "" + +#: ClientCommand.cpp:1693 +msgctxt "helpcmd|ListNicks|args" +msgid "<#chan>" +msgstr "" + +#: ClientCommand.cpp:1694 +msgctxt "helpcmd|ListNicks|desc" +msgid "List all nicks on a channel" +msgstr "" + +#: ClientCommand.cpp:1697 +msgctxt "helpcmd|ListClients|desc" +msgid "List all clients connected to your ZNC user" +msgstr "" + +#: ClientCommand.cpp:1701 +msgctxt "helpcmd|ListServers|desc" +msgid "List all servers of current IRC network" +msgstr "" + +#: ClientCommand.cpp:1705 +msgctxt "helpcmd|AddNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1706 +msgctxt "helpcmd|AddNetwork|desc" +msgid "Add a network to your user" +msgstr "" + +#: ClientCommand.cpp:1708 +msgctxt "helpcmd|DelNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1709 +msgctxt "helpcmd|DelNetwork|desc" +msgid "Delete a network from your user" +msgstr "" + +#: ClientCommand.cpp:1711 +msgctxt "helpcmd|ListNetworks|desc" +msgid "List all networks" +msgstr "" + +#: ClientCommand.cpp:1714 +msgctxt "helpcmd|MoveNetwork|args" +msgid " [new network]" +msgstr "" + +#: ClientCommand.cpp:1716 +msgctxt "helpcmd|MoveNetwork|desc" +msgid "Move an IRC network from one user to another" +msgstr "" + +#: ClientCommand.cpp:1720 +msgctxt "helpcmd|JumpNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1721 +msgctxt "helpcmd|JumpNetwork|desc" +msgid "" +"Jump to another network (Alternatively, you can connect to ZNC several " +"times, using `user/network` as username)" +msgstr "" + +#: ClientCommand.cpp:1726 +msgctxt "helpcmd|AddServer|args" +msgid " [[+]port] [pass]" +msgstr "" + +#: ClientCommand.cpp:1727 +msgctxt "helpcmd|AddServer|desc" +msgid "" +"Add a server to the list of alternate/backup servers of current IRC network." +msgstr "" + +#: ClientCommand.cpp:1731 +msgctxt "helpcmd|DelServer|args" +msgid " [port] [pass]" +msgstr "" + +#: ClientCommand.cpp:1732 +msgctxt "helpcmd|DelServer|desc" +msgid "" +"Remove a server from the list of alternate/backup servers of current IRC " +"network" +msgstr "" + +#: ClientCommand.cpp:1738 +msgctxt "helpcmd|AddTrustedServerFingerprint|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1739 +msgctxt "helpcmd|AddTrustedServerFingerprint|desc" +msgid "" +"Add a trusted server SSL certificate fingerprint (SHA-256) to current IRC " +"network." +msgstr "" + +#: ClientCommand.cpp:1744 +msgctxt "helpcmd|DelTrustedServerFingerprint|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1745 +msgctxt "helpcmd|DelTrustedServerFingerprint|desc" +msgid "Delete a trusted server SSL certificate from current IRC network." +msgstr "" + +#: ClientCommand.cpp:1749 +msgctxt "helpcmd|ListTrustedServerFingerprints|desc" +msgid "List all trusted server SSL certificates of current IRC network." +msgstr "" + +#: ClientCommand.cpp:1752 +msgctxt "helpcmd|EnableChan|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1753 +msgctxt "helpcmd|EnableChan|desc" +msgid "Enable channels" +msgstr "" + +#: ClientCommand.cpp:1754 +msgctxt "helpcmd|DisableChan|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1755 +msgctxt "helpcmd|DisableChan|desc" +msgid "Disable channels" +msgstr "" + +#: ClientCommand.cpp:1756 +msgctxt "helpcmd|Attach|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1757 +msgctxt "helpcmd|Attach|desc" +msgid "Attach to channels" +msgstr "" + +#: ClientCommand.cpp:1758 +msgctxt "helpcmd|Detach|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1759 +msgctxt "helpcmd|Detach|desc" +msgid "Detach from channels" +msgstr "" + +#: ClientCommand.cpp:1762 +msgctxt "helpcmd|Topics|desc" +msgid "Show topics in all your channels" +msgstr "" + +#: ClientCommand.cpp:1765 +msgctxt "helpcmd|PlayBuffer|args" +msgid "<#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1766 +msgctxt "helpcmd|PlayBuffer|desc" +msgid "Play back the specified buffer" +msgstr "" + +#: ClientCommand.cpp:1768 +msgctxt "helpcmd|ClearBuffer|args" +msgid "<#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1769 +msgctxt "helpcmd|ClearBuffer|desc" +msgid "Clear the specified buffer" +msgstr "" + +#: ClientCommand.cpp:1771 +msgctxt "helpcmd|ClearAllBuffers|desc" +msgid "Clear all channel and query buffers" +msgstr "" + +#: ClientCommand.cpp:1774 +msgctxt "helpcmd|ClearAllChannelBuffers|desc" +msgid "Clear the channel buffers" +msgstr "" + +#: ClientCommand.cpp:1778 +msgctxt "helpcmd|ClearAllQueryBuffers|desc" +msgid "Clear the query buffers" +msgstr "" + +#: ClientCommand.cpp:1780 +msgctxt "helpcmd|SetBuffer|args" +msgid "<#chan|query> [linecount]" +msgstr "" + +#: ClientCommand.cpp:1781 +msgctxt "helpcmd|SetBuffer|desc" +msgid "Set the buffer count" +msgstr "" + +#: ClientCommand.cpp:1785 +msgctxt "helpcmd|SetBindHost|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1786 +msgctxt "helpcmd|SetBindHost|desc" +msgid "Set the bind host for this network" +msgstr "" + +#: ClientCommand.cpp:1790 +msgctxt "helpcmd|SetUserBindHost|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1791 +msgctxt "helpcmd|SetUserBindHost|desc" +msgid "Set the default bind host for this user" +msgstr "" + +#: ClientCommand.cpp:1794 +msgctxt "helpcmd|ClearBindHost|desc" +msgid "Clear the bind host for this network" +msgstr "" + +#: ClientCommand.cpp:1797 +msgctxt "helpcmd|ClearUserBindHost|desc" +msgid "Clear the default bind host for this user" +msgstr "" + +#: ClientCommand.cpp:1803 +msgctxt "helpcmd|ShowBindHost|desc" +msgid "Show currently selected bind host" +msgstr "" + +#: ClientCommand.cpp:1805 +msgctxt "helpcmd|Jump|args" +msgid "[server]" +msgstr "" + +#: ClientCommand.cpp:1806 +msgctxt "helpcmd|Jump|desc" +msgid "Jump to the next or the specified server" +msgstr "" + +#: ClientCommand.cpp:1807 +msgctxt "helpcmd|Disconnect|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1808 +msgctxt "helpcmd|Disconnect|desc" +msgid "Disconnect from IRC" +msgstr "" + +#: ClientCommand.cpp:1810 +msgctxt "helpcmd|Connect|desc" +msgid "Reconnect to IRC" +msgstr "" + +#: ClientCommand.cpp:1813 +msgctxt "helpcmd|Uptime|desc" +msgid "Show for how long ZNC has been running" +msgstr "" + +#: ClientCommand.cpp:1817 +msgctxt "helpcmd|LoadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1819 +msgctxt "helpcmd|LoadMod|desc" +msgid "Load a module" +msgstr "" + +#: ClientCommand.cpp:1821 +msgctxt "helpcmd|UnloadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1823 +msgctxt "helpcmd|UnloadMod|desc" +msgid "Unload a module" +msgstr "" + +#: ClientCommand.cpp:1825 +msgctxt "helpcmd|ReloadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1827 +msgctxt "helpcmd|ReloadMod|desc" +msgid "Reload a module" +msgstr "" + +#: ClientCommand.cpp:1830 +msgctxt "helpcmd|UpdateMod|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1831 +msgctxt "helpcmd|UpdateMod|desc" +msgid "Reload a module everywhere" +msgstr "" + +#: ClientCommand.cpp:1837 +msgctxt "helpcmd|ShowMOTD|desc" +msgid "Show ZNC's message of the day" +msgstr "" + +#: ClientCommand.cpp:1841 +msgctxt "helpcmd|SetMOTD|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1842 +msgctxt "helpcmd|SetMOTD|desc" +msgid "Set ZNC's message of the day" +msgstr "" + +#: ClientCommand.cpp:1844 +msgctxt "helpcmd|AddMOTD|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1845 +msgctxt "helpcmd|AddMOTD|desc" +msgid "Append to ZNC's MOTD" +msgstr "" + +#: ClientCommand.cpp:1847 +msgctxt "helpcmd|ClearMOTD|desc" +msgid "Clear ZNC's MOTD" +msgstr "" + +#: ClientCommand.cpp:1850 +msgctxt "helpcmd|ListPorts|desc" +msgid "Show all active listeners" +msgstr "" + +#: ClientCommand.cpp:1852 +msgctxt "helpcmd|AddPort|args" +msgid "<[+]port> [bindhost [uriprefix]]" +msgstr "" + +#: ClientCommand.cpp:1855 +msgctxt "helpcmd|AddPort|desc" +msgid "Add another port for ZNC to listen on" +msgstr "" + +#: ClientCommand.cpp:1859 +msgctxt "helpcmd|DelPort|args" +msgid " [bindhost]" +msgstr "" + +#: ClientCommand.cpp:1860 +msgctxt "helpcmd|DelPort|desc" +msgid "Remove a port from ZNC" +msgstr "" + +#: ClientCommand.cpp:1863 +msgctxt "helpcmd|Rehash|desc" +msgid "Reload global settings, modules, and listeners from znc.conf" +msgstr "" + +#: ClientCommand.cpp:1866 +msgctxt "helpcmd|SaveConfig|desc" +msgid "Save the current settings to disk" +msgstr "" + +#: ClientCommand.cpp:1869 +msgctxt "helpcmd|ListUsers|desc" +msgid "List all ZNC users and their connection status" +msgstr "" + +#: ClientCommand.cpp:1872 +msgctxt "helpcmd|ListAllUserNetworks|desc" +msgid "List all ZNC users and their networks" +msgstr "" + +#: ClientCommand.cpp:1875 +msgctxt "helpcmd|ListChans|args" +msgid "[user ]" +msgstr "" + +#: ClientCommand.cpp:1878 +msgctxt "helpcmd|ListClients|args" +msgid "[user]" +msgstr "" + +#: ClientCommand.cpp:1879 +msgctxt "helpcmd|ListClients|desc" +msgid "List all connected clients" +msgstr "" + +#: ClientCommand.cpp:1881 +msgctxt "helpcmd|Traffic|desc" +msgid "Show basic traffic stats for all ZNC users" +msgstr "" + +#: ClientCommand.cpp:1883 +msgctxt "helpcmd|Broadcast|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1884 +msgctxt "helpcmd|Broadcast|desc" +msgid "Broadcast a message to all ZNC users" +msgstr "" + +#: ClientCommand.cpp:1887 +msgctxt "helpcmd|Shutdown|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1888 +msgctxt "helpcmd|Shutdown|desc" +msgid "Shut down ZNC completely" +msgstr "" + +#: ClientCommand.cpp:1889 +msgctxt "helpcmd|Restart|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1890 +msgctxt "helpcmd|Restart|desc" +msgid "Restart ZNC" +msgstr "" + +#: ClientCommand.cpp:1894 +msgid "No matches for '{1}'" +msgstr "" diff --git a/src/po/znc.ru.po b/src/po/znc.ru.po index a2bcdb4a..30f03514 100644 --- a/src/po/znc.ru.po +++ b/src/po/znc.ru.po @@ -116,7 +116,7 @@ msgstr[3] "" #: ClientCommand.cpp:132 msgid "Attached {1} channel" -msgid_plural "Attached {2} channels" +msgid_plural "Attached {1} channels" msgstr[0] "" msgstr[1] "" msgstr[2] "" @@ -128,7 +128,7 @@ msgstr "" #: ClientCommand.cpp:154 msgid "Detached {1} channel" -msgid_plural "Detached {2} channels" +msgid_plural "Detached {1} channels" msgstr[0] "" msgstr[1] "" msgstr[2] "" @@ -899,3 +899,480 @@ msgstr "" #: ClientCommand.cpp:1651 msgid "Unable to find a matching port" msgstr "" + +#: ClientCommand.cpp:1659 ClientCommand.cpp:1673 +msgctxt "helpcmd" +msgid "Command" +msgstr "" + +#: ClientCommand.cpp:1660 ClientCommand.cpp:1674 +msgctxt "helpcmd" +msgid "Description" +msgstr "" + +#: ClientCommand.cpp:1664 +msgid "" +"In the following list all occurrences of <#chan> support wildcards (* and ?) " +"except ListNicks" +msgstr "" + +#: ClientCommand.cpp:1680 +msgctxt "helpcmd|Version|desc" +msgid "Print which version of ZNC this is" +msgstr "" + +#: ClientCommand.cpp:1683 +msgctxt "helpcmd|ListMods|desc" +msgid "List all loaded modules" +msgstr "" + +#: ClientCommand.cpp:1686 +msgctxt "helpcmd|ListAvailMods|desc" +msgid "List all available modules" +msgstr "" + +#: ClientCommand.cpp:1690 ClientCommand.cpp:1876 +msgctxt "helpcmd|ListChans|desc" +msgid "List all channels" +msgstr "" + +#: ClientCommand.cpp:1693 +msgctxt "helpcmd|ListNicks|args" +msgid "<#chan>" +msgstr "" + +#: ClientCommand.cpp:1694 +msgctxt "helpcmd|ListNicks|desc" +msgid "List all nicks on a channel" +msgstr "" + +#: ClientCommand.cpp:1697 +msgctxt "helpcmd|ListClients|desc" +msgid "List all clients connected to your ZNC user" +msgstr "" + +#: ClientCommand.cpp:1701 +msgctxt "helpcmd|ListServers|desc" +msgid "List all servers of current IRC network" +msgstr "" + +#: ClientCommand.cpp:1705 +msgctxt "helpcmd|AddNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1706 +msgctxt "helpcmd|AddNetwork|desc" +msgid "Add a network to your user" +msgstr "" + +#: ClientCommand.cpp:1708 +msgctxt "helpcmd|DelNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1709 +msgctxt "helpcmd|DelNetwork|desc" +msgid "Delete a network from your user" +msgstr "" + +#: ClientCommand.cpp:1711 +msgctxt "helpcmd|ListNetworks|desc" +msgid "List all networks" +msgstr "" + +#: ClientCommand.cpp:1714 +msgctxt "helpcmd|MoveNetwork|args" +msgid " [new network]" +msgstr "" + +#: ClientCommand.cpp:1716 +msgctxt "helpcmd|MoveNetwork|desc" +msgid "Move an IRC network from one user to another" +msgstr "" + +#: ClientCommand.cpp:1720 +msgctxt "helpcmd|JumpNetwork|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1721 +msgctxt "helpcmd|JumpNetwork|desc" +msgid "" +"Jump to another network (Alternatively, you can connect to ZNC several " +"times, using `user/network` as username)" +msgstr "" + +#: ClientCommand.cpp:1726 +msgctxt "helpcmd|AddServer|args" +msgid " [[+]port] [pass]" +msgstr "" + +#: ClientCommand.cpp:1727 +msgctxt "helpcmd|AddServer|desc" +msgid "" +"Add a server to the list of alternate/backup servers of current IRC network." +msgstr "" + +#: ClientCommand.cpp:1731 +msgctxt "helpcmd|DelServer|args" +msgid " [port] [pass]" +msgstr "" + +#: ClientCommand.cpp:1732 +msgctxt "helpcmd|DelServer|desc" +msgid "" +"Remove a server from the list of alternate/backup servers of current IRC " +"network" +msgstr "" + +#: ClientCommand.cpp:1738 +msgctxt "helpcmd|AddTrustedServerFingerprint|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1739 +msgctxt "helpcmd|AddTrustedServerFingerprint|desc" +msgid "" +"Add a trusted server SSL certificate fingerprint (SHA-256) to current IRC " +"network." +msgstr "" + +#: ClientCommand.cpp:1744 +msgctxt "helpcmd|DelTrustedServerFingerprint|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1745 +msgctxt "helpcmd|DelTrustedServerFingerprint|desc" +msgid "Delete a trusted server SSL certificate from current IRC network." +msgstr "" + +#: ClientCommand.cpp:1749 +msgctxt "helpcmd|ListTrustedServerFingerprints|desc" +msgid "List all trusted server SSL certificates of current IRC network." +msgstr "" + +#: ClientCommand.cpp:1752 +msgctxt "helpcmd|EnableChan|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1753 +msgctxt "helpcmd|EnableChan|desc" +msgid "Enable channels" +msgstr "" + +#: ClientCommand.cpp:1754 +msgctxt "helpcmd|DisableChan|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1755 +msgctxt "helpcmd|DisableChan|desc" +msgid "Disable channels" +msgstr "" + +#: ClientCommand.cpp:1756 +msgctxt "helpcmd|Attach|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1757 +msgctxt "helpcmd|Attach|desc" +msgid "Attach to channels" +msgstr "" + +#: ClientCommand.cpp:1758 +msgctxt "helpcmd|Detach|args" +msgid "<#chans>" +msgstr "" + +#: ClientCommand.cpp:1759 +msgctxt "helpcmd|Detach|desc" +msgid "Detach from channels" +msgstr "" + +#: ClientCommand.cpp:1762 +msgctxt "helpcmd|Topics|desc" +msgid "Show topics in all your channels" +msgstr "" + +#: ClientCommand.cpp:1765 +msgctxt "helpcmd|PlayBuffer|args" +msgid "<#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1766 +msgctxt "helpcmd|PlayBuffer|desc" +msgid "Play back the specified buffer" +msgstr "" + +#: ClientCommand.cpp:1768 +msgctxt "helpcmd|ClearBuffer|args" +msgid "<#chan|query>" +msgstr "" + +#: ClientCommand.cpp:1769 +msgctxt "helpcmd|ClearBuffer|desc" +msgid "Clear the specified buffer" +msgstr "" + +#: ClientCommand.cpp:1771 +msgctxt "helpcmd|ClearAllBuffers|desc" +msgid "Clear all channel and query buffers" +msgstr "" + +#: ClientCommand.cpp:1774 +msgctxt "helpcmd|ClearAllChannelBuffers|desc" +msgid "Clear the channel buffers" +msgstr "" + +#: ClientCommand.cpp:1778 +msgctxt "helpcmd|ClearAllQueryBuffers|desc" +msgid "Clear the query buffers" +msgstr "" + +#: ClientCommand.cpp:1780 +msgctxt "helpcmd|SetBuffer|args" +msgid "<#chan|query> [linecount]" +msgstr "" + +#: ClientCommand.cpp:1781 +msgctxt "helpcmd|SetBuffer|desc" +msgid "Set the buffer count" +msgstr "" + +#: ClientCommand.cpp:1785 +msgctxt "helpcmd|SetBindHost|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1786 +msgctxt "helpcmd|SetBindHost|desc" +msgid "Set the bind host for this network" +msgstr "" + +#: ClientCommand.cpp:1790 +msgctxt "helpcmd|SetUserBindHost|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1791 +msgctxt "helpcmd|SetUserBindHost|desc" +msgid "Set the default bind host for this user" +msgstr "" + +#: ClientCommand.cpp:1794 +msgctxt "helpcmd|ClearBindHost|desc" +msgid "Clear the bind host for this network" +msgstr "" + +#: ClientCommand.cpp:1797 +msgctxt "helpcmd|ClearUserBindHost|desc" +msgid "Clear the default bind host for this user" +msgstr "" + +#: ClientCommand.cpp:1803 +msgctxt "helpcmd|ShowBindHost|desc" +msgid "Show currently selected bind host" +msgstr "" + +#: ClientCommand.cpp:1805 +msgctxt "helpcmd|Jump|args" +msgid "[server]" +msgstr "" + +#: ClientCommand.cpp:1806 +msgctxt "helpcmd|Jump|desc" +msgid "Jump to the next or the specified server" +msgstr "" + +#: ClientCommand.cpp:1807 +msgctxt "helpcmd|Disconnect|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1808 +msgctxt "helpcmd|Disconnect|desc" +msgid "Disconnect from IRC" +msgstr "" + +#: ClientCommand.cpp:1810 +msgctxt "helpcmd|Connect|desc" +msgid "Reconnect to IRC" +msgstr "" + +#: ClientCommand.cpp:1813 +msgctxt "helpcmd|Uptime|desc" +msgid "Show for how long ZNC has been running" +msgstr "" + +#: ClientCommand.cpp:1817 +msgctxt "helpcmd|LoadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1819 +msgctxt "helpcmd|LoadMod|desc" +msgid "Load a module" +msgstr "" + +#: ClientCommand.cpp:1821 +msgctxt "helpcmd|UnloadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1823 +msgctxt "helpcmd|UnloadMod|desc" +msgid "Unload a module" +msgstr "" + +#: ClientCommand.cpp:1825 +msgctxt "helpcmd|ReloadMod|args" +msgid "[--type=global|user|network] " +msgstr "" + +#: ClientCommand.cpp:1827 +msgctxt "helpcmd|ReloadMod|desc" +msgid "Reload a module" +msgstr "" + +#: ClientCommand.cpp:1830 +msgctxt "helpcmd|UpdateMod|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1831 +msgctxt "helpcmd|UpdateMod|desc" +msgid "Reload a module everywhere" +msgstr "" + +#: ClientCommand.cpp:1837 +msgctxt "helpcmd|ShowMOTD|desc" +msgid "Show ZNC's message of the day" +msgstr "" + +#: ClientCommand.cpp:1841 +msgctxt "helpcmd|SetMOTD|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1842 +msgctxt "helpcmd|SetMOTD|desc" +msgid "Set ZNC's message of the day" +msgstr "" + +#: ClientCommand.cpp:1844 +msgctxt "helpcmd|AddMOTD|args" +msgid "" +msgstr "" + +#: ClientCommand.cpp:1845 +msgctxt "helpcmd|AddMOTD|desc" +msgid "Append to ZNC's MOTD" +msgstr "" + +#: ClientCommand.cpp:1847 +msgctxt "helpcmd|ClearMOTD|desc" +msgid "Clear ZNC's MOTD" +msgstr "" + +#: ClientCommand.cpp:1850 +msgctxt "helpcmd|ListPorts|desc" +msgid "Show all active listeners" +msgstr "" + +#: ClientCommand.cpp:1852 +msgctxt "helpcmd|AddPort|args" +msgid "<[+]port> [bindhost [uriprefix]]" +msgstr "" + +#: ClientCommand.cpp:1855 +msgctxt "helpcmd|AddPort|desc" +msgid "Add another port for ZNC to listen on" +msgstr "" + +#: ClientCommand.cpp:1859 +msgctxt "helpcmd|DelPort|args" +msgid " [bindhost]" +msgstr "" + +#: ClientCommand.cpp:1860 +msgctxt "helpcmd|DelPort|desc" +msgid "Remove a port from ZNC" +msgstr "" + +#: ClientCommand.cpp:1863 +msgctxt "helpcmd|Rehash|desc" +msgid "Reload global settings, modules, and listeners from znc.conf" +msgstr "" + +#: ClientCommand.cpp:1866 +msgctxt "helpcmd|SaveConfig|desc" +msgid "Save the current settings to disk" +msgstr "" + +#: ClientCommand.cpp:1869 +msgctxt "helpcmd|ListUsers|desc" +msgid "List all ZNC users and their connection status" +msgstr "" + +#: ClientCommand.cpp:1872 +msgctxt "helpcmd|ListAllUserNetworks|desc" +msgid "List all ZNC users and their networks" +msgstr "" + +#: ClientCommand.cpp:1875 +msgctxt "helpcmd|ListChans|args" +msgid "[user ]" +msgstr "" + +#: ClientCommand.cpp:1878 +msgctxt "helpcmd|ListClients|args" +msgid "[user]" +msgstr "" + +#: ClientCommand.cpp:1879 +msgctxt "helpcmd|ListClients|desc" +msgid "List all connected clients" +msgstr "" + +#: ClientCommand.cpp:1881 +msgctxt "helpcmd|Traffic|desc" +msgid "Show basic traffic stats for all ZNC users" +msgstr "" + +#: ClientCommand.cpp:1883 +msgctxt "helpcmd|Broadcast|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1884 +msgctxt "helpcmd|Broadcast|desc" +msgid "Broadcast a message to all ZNC users" +msgstr "" + +#: ClientCommand.cpp:1887 +msgctxt "helpcmd|Shutdown|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1888 +msgctxt "helpcmd|Shutdown|desc" +msgid "Shut down ZNC completely" +msgstr "" + +#: ClientCommand.cpp:1889 +msgctxt "helpcmd|Restart|args" +msgid "[message]" +msgstr "" + +#: ClientCommand.cpp:1890 +msgctxt "helpcmd|Restart|desc" +msgid "Restart ZNC" +msgstr "" + +#: ClientCommand.cpp:1894 +msgid "No matches for '{1}'" +msgstr "" From 1eceb5a5c76dca8feda6b693b871b84441fe7fd0 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Sat, 31 Mar 2018 22:29:09 +0100 Subject: [PATCH 11/20] More translateable strings (#1354) --- include/znc/Client.h | 2 +- include/znc/IRCNetwork.h | 2 +- include/znc/Modules.h | 4 +- src/Client.cpp | 81 +++++++++++++++++++++------------------- src/IRCNetwork.cpp | 33 +++++++++------- src/IRCSock.cpp | 50 ++++++++++++------------- src/Modules.cpp | 80 +++++++++++++++++++-------------------- 7 files changed, 129 insertions(+), 123 deletions(-) diff --git a/include/znc/Client.h b/include/znc/Client.h index e52b2ec8..6d33a3f3 100644 --- a/include/znc/Client.h +++ b/include/znc/Client.h @@ -35,7 +35,7 @@ class CMessage; class CChan; // !Forward Declarations -class CAuthBase { +class CAuthBase : private CCoreTranslationMixin { public: CAuthBase(const CString& sUsername, const CString& sPassword, CZNCSock* pSock) diff --git a/include/znc/IRCNetwork.h b/include/znc/IRCNetwork.h index 0f989ef6..ee5ba8db 100644 --- a/include/znc/IRCNetwork.h +++ b/include/znc/IRCNetwork.h @@ -37,7 +37,7 @@ class CIRCNetworkPingTimer; class CIRCNetworkJoinTimer; class CMessage; -class CIRCNetwork { +class CIRCNetwork : private CCoreTranslationMixin { public: static bool IsValidNetwork(const CString& sNetwork); diff --git a/include/znc/Modules.h b/include/znc/Modules.h index ce0a39ff..28fdd3a6 100644 --- a/include/znc/Modules.h +++ b/include/znc/Modules.h @@ -335,7 +335,7 @@ CModule* TModLoad(ModHandle p, CUser* pUser, CIRCNetwork* pNetwork, } /** A helper class for handling commands in modules. */ -class CModCommand { +class CModCommand : private CCoreTranslationMixin { public: /// Type for the callback function that handles the actual command. typedef void (CModule::*ModCmdFunc)(const CString& sLine); @@ -1386,7 +1386,7 @@ class CModule { std::map m_mCommands; }; -class CModules : public std::vector { +class CModules : public std::vector, private CCoreTranslationMixin { public: CModules(); ~CModules(); diff --git a/src/Client.cpp b/src/Client.cpp index a39d6d39..c8c7c23c 100644 --- a/src/Client.cpp +++ b/src/Client.cpp @@ -72,7 +72,7 @@ using std::vector; } \ } \ } else { \ - PutStatus("No such module [" + MOD + "]"); \ + PutStatus(t_f("No such module {1}")(MOD)); \ } \ } @@ -361,9 +361,9 @@ void CAuthBase::RefuseLogin(const CString& sReason) { // login. Use sReason because there are other reasons than "wrong // password" for a login to be rejected (e.g. fail2ban). if (pUser) { - pUser->PutStatusNotice("A client from [" + GetRemoteIP() + "] attempted " - "to login as you, but was rejected [" + - sReason + "]."); + pUser->PutStatusNotice(t_f( + "A client from {1} attempted to login as you, but was rejected: " + "{2}")(GetRemoteIP(), sReason)); } GLOBALMODULECALL(OnFailedLogin(GetUsername(), GetRemoteIP()), NOTHING); @@ -397,7 +397,7 @@ void CClient::AcceptLogin(CUser& User) { if (!m_sNetwork.empty()) { m_pNetwork = m_pUser->FindNetwork(m_sNetwork); if (!m_pNetwork) { - PutStatus("Network (" + m_sNetwork + ") doesn't exist."); + PutStatus(t_f("Network {1} doesn't exist.")(m_sNetwork)); } } else if (!m_pUser->GetNetworks().empty()) { // If a user didn't supply a network, and they have a network called @@ -411,21 +411,20 @@ void CClient::AcceptLogin(CUser& User) { if (!m_pNetwork) m_pNetwork = *m_pUser->GetNetworks().begin(); if (m_pNetwork && m_pUser->GetNetworks().size() > 1) { PutStatusNotice( - "You have several networks configured, but no network was " - "specified for the connection."); - PutStatusNotice("Selecting network [" + m_pNetwork->GetName() + - "]. To see list of all configured networks, use " - "/znc ListNetworks"); + t_s("You have several networks configured, but no network was " + "specified for the connection.")); PutStatusNotice( + t_f("Selecting network {1}. To see list of all configured " + "networks, use /znc ListNetworks")(m_pNetwork->GetName())); + PutStatusNotice(t_f( "If you want to choose another network, use /znc JumpNetwork " - ", or connect to ZNC with username " + - m_pUser->GetUserName() + "/ (instead of just " + - m_pUser->GetUserName() + ")"); + ", or connect to ZNC with username {1}/ " + "(instead of just {1})")(m_pUser->GetUserName())); } } else { PutStatusNotice( - "You have no networks configured. Use /znc AddNetwork to " - "add one."); + t_s("You have no networks configured. Use /znc AddNetwork " + " to add one.")); } SetNetwork(m_pNetwork, false); @@ -435,7 +434,7 @@ void CClient::AcceptLogin(CUser& User) { NETWORKMODULECALL(OnClientLogin(), m_pUser, m_pNetwork, this, NOTHING); } -void CClient::Timeout() { PutClient("ERROR :Closing link [Timeout]"); } +void CClient::Timeout() { PutClient("ERROR :" + t_s("Closing link: Timeout")); } void CClient::Connected() { DEBUG(GetSockName() << " == Connected();"); } @@ -457,15 +456,15 @@ void CClient::Disconnected() { void CClient::ReachedMaxBuffer() { DEBUG(GetSockName() << " == ReachedMaxBuffer()"); if (IsAttached()) { - PutClient("ERROR :Closing link [Too long raw line]"); + PutClient("ERROR :" + t_s("Closing link: Too long raw line")); } Close(); } void CClient::BouncedOff() { PutStatusNotice( - "You are being disconnected because another user just authenticated as " - "you."); + t_s("You are being disconnected because another user just " + "authenticated as you.")); Close(Csock::CLT_AFTERWRITE); } @@ -1018,9 +1017,9 @@ bool CClient::OnCTCPMessage(CCTCPMessage& Message) { if (!GetIRCSock()) { // Some lagmeters do a NOTICE to their own nick, ignore those. if (!sTarget.Equals(m_sNick)) - PutStatus("Your CTCP to [" + Message.GetTarget() + - "] got lost, " - "you are not connected to IRC!"); + PutStatus(t_f( + "Your CTCP to {1} got lost, you are not connected to IRC!")( + Message.GetTarget())); continue; } @@ -1145,9 +1144,9 @@ bool CClient::OnNoticeMessage(CNoticeMessage& Message) { if (!GetIRCSock()) { // Some lagmeters do a NOTICE to their own nick, ignore those. if (!sTarget.Equals(m_sNick)) - PutStatus("Your notice to [" + Message.GetTarget() + - "] got lost, " - "you are not connected to IRC!"); + PutStatus( + t_f("Your notice to {1} got lost, you are not connected to " + "IRC!")(Message.GetTarget())); continue; } @@ -1185,7 +1184,7 @@ bool CClient::OnPartMessage(CPartMessage& Message) { CChan* pChan = m_pNetwork ? m_pNetwork->FindChan(sChan) : nullptr; if (pChan && !pChan->IsOn()) { - PutStatusNotice("Removing channel [" + sChan + "]"); + PutStatusNotice(t_f("Removing channel {1}")(sChan)); m_pNetwork->DelChan(sChan); } else { sChans += (sChans.empty()) ? sChan : CString("," + sChan); @@ -1261,9 +1260,9 @@ bool CClient::OnTextMessage(CTextMessage& Message) { if (!GetIRCSock()) { // Some lagmeters do a PRIVMSG to their own nick, ignore those. if (!sTarget.Equals(m_sNick)) - PutStatus("Your message to [" + Message.GetTarget() + - "] got lost, " - "you are not connected to IRC!"); + PutStatus( + t_f("Your message to {1} got lost, you are not connected " + "to IRC!")(Message.GetTarget())); continue; } @@ -1315,13 +1314,13 @@ bool CClient::OnOtherMessage(CMessage& Message) { if (sTarget.Equals("status")) { if (sModCommand.empty()) - PutStatus("Hello. How may I help you?"); + PutStatus(t_s("Hello. How may I help you?")); else UserCommand(sModCommand); } else { if (sModCommand.empty()) CALLMOD(sTarget, this, m_pUser, m_pNetwork, - PutModule("Hello. How may I help you?")) + PutModule(t_s("Hello. How may I help you?"))) else CALLMOD(sTarget, this, m_pUser, m_pNetwork, OnModCommand(sModCommand)) @@ -1335,16 +1334,18 @@ bool CClient::OnOtherMessage(CMessage& Message) { CString sPatterns = Message.GetParams(0); if (sPatterns.empty()) { - PutStatusNotice("Usage: /attach <#chans>"); + PutStatusNotice(t_s("Usage: /attach <#chans>")); return true; } set sChans = MatchChans(sPatterns); unsigned int uAttachedChans = AttachChans(sChans); - PutStatusNotice("There were [" + CString(sChans.size()) + - "] channels matching [" + sPatterns + "]"); - PutStatusNotice("Attached [" + CString(uAttachedChans) + "] channels"); + PutStatusNotice(t_p("There was {1} channel matching [{2}]", + "There were {1} channels matching [{2}]", + sChans.size())(sChans.size(), sPatterns)); + PutStatusNotice(t_p("Attached {1} channel", "Attached {1} channels", + uAttachedChans)(uAttachedChans)); return true; } else if (sCommand.Equals("DETACH")) { @@ -1355,16 +1356,18 @@ bool CClient::OnOtherMessage(CMessage& Message) { CString sPatterns = Message.GetParams(0); if (sPatterns.empty()) { - PutStatusNotice("Usage: /detach <#chans>"); + PutStatusNotice(t_s("Usage: /detach <#chans>")); return true; } set sChans = MatchChans(sPatterns); unsigned int uDetached = DetachChans(sChans); - PutStatusNotice("There were [" + CString(sChans.size()) + - "] channels matching [" + sPatterns + "]"); - PutStatusNotice("Detached [" + CString(uDetached) + "] channels"); + PutStatusNotice(t_p("There was {1} channel matching [{2}]", + "There were {1} channels matching [{2}]", + sChans.size())(sChans.size(), sPatterns)); + PutStatusNotice(t_p("Detached {1} channel", "Detached {1} channels", + uDetached)(uDetached)); return true; } else if (sCommand.Equals("PROTOCTL")) { diff --git a/src/IRCNetwork.cpp b/src/IRCNetwork.cpp index 6ad65e6a..217096f2 100644 --- a/src/IRCNetwork.cpp +++ b/src/IRCNetwork.cpp @@ -233,7 +233,8 @@ void CIRCNetwork::Clone(const CIRCNetwork& Network, bool bCloneName) { if (pSock) { PutStatus( - "Jumping servers because this server is no longer in the list"); + t_s("Jumping servers because this server is no longer in the " + "list")); pSock->Quit(); } } @@ -468,7 +469,9 @@ bool CIRCNetwork::ParseConfig(CConfig* pConfig, CString& sError, } if (!bFound) { sNotice = - "Loading network module [simple_away] instead"; + "NOTICE: awaynick was retired, loading network " + "module [simple_away] instead; if you still need " + "awaynick, install it as an external module"; sModName = "simple_away"; // not a fatal error if simple_away is not available LoadModule(sModName, sArgs, sNotice, sModRet); @@ -635,7 +638,7 @@ void CIRCNetwork::ClientConnected(CClient* pClient) { if (m_RawBuffer.IsEmpty()) { pClient->PutClient(":irc.znc.in 001 " + pClient->GetNick() + - " :- Welcome to ZNC -"); + " :" + t_s("Welcome to ZNC")); } else { const CString& sClientNick = pClient->GetNick(false); MCString msParams; @@ -723,12 +726,13 @@ void CIRCNetwork::ClientConnected(CClient* pClient) { // Tell them why they won't connect if (!GetIRCConnectEnabled()) pClient->PutStatus( - "You are currently disconnected from IRC. " - "Use 'connect' to reconnect."); + t_s("You are currently disconnected from IRC. Use 'connect' to " + "reconnect.")); if (CDebug::Debug()) { - pClient->PutStatus("ZNC is presently running in DEBUG mode. Sensitive" - " data during your current session may be exposed to the host."); + pClient->PutStatus( + t_s("ZNC is presently running in DEBUG mode. Sensitive data during " + "your current session may be exposed to the host.")); } } @@ -758,7 +762,7 @@ std::vector CIRCNetwork::FindClients( void CIRCNetwork::SetUser(CUser* pUser) { for (CClient* pClient : m_vClients) { pClient->PutStatus( - "This network is being deleted or moved to another user."); + t_s("This network is being deleted or moved to another user.")); pClient->SetNetwork(nullptr); } @@ -987,8 +991,8 @@ bool CIRCNetwork::JoinChan(CChan* pChan) { if (m_pUser->JoinTries() != 0 && pChan->GetJoinTries() >= m_pUser->JoinTries()) { - PutStatus("The channel " + pChan->GetName() + - " could not be joined, disabling it."); + PutStatus(t_f("The channel {1} could not be joined, disabling it.")( + pChan->GetName())); pChan->Disable(); } else { pChan->IncJoinTries(); @@ -1116,7 +1120,7 @@ bool CIRCNetwork::DelServer(const CString& sName, unsigned short uPort, if (pIRCSock) { pIRCSock->Quit(); - PutStatus("Your current server was removed, jumping..."); + PutStatus(t_s("Your current server was removed, jumping...")); } } else if (!bSawCurrentServer) { // Our current server comes after the server which we @@ -1278,8 +1282,9 @@ bool CIRCNetwork::Connect() { bool bSSL = pServer->IsSSL(); #ifndef HAVE_LIBSSL if (bSSL) { - PutStatus("Cannot connect to [" + pServer->GetString(false) + - "], ZNC is not compiled with SSL."); + PutStatus( + t_f("Cannot connect to {1}, because ZNC is not compiled with SSL " + "support.")(pServer->GetString(false))); CZNC::Get().AddNetworkToQueue(this); return false; } @@ -1299,7 +1304,7 @@ bool CIRCNetwork::Connect() { &bAbort); if (bAbort) { DEBUG("Some module aborted the connection attempt"); - PutStatus("Some module aborted the connection attempt"); + PutStatus(t_s("Some module aborted the connection attempt")); delete pIRCSock; CZNC::Get().AddNetworkToQueue(this); return false; diff --git a/src/IRCSock.cpp b/src/IRCSock.cpp index 53734706..2aef7663 100644 --- a/src/IRCSock.cpp +++ b/src/IRCSock.cpp @@ -481,7 +481,7 @@ bool CIRCSock::OnCTCPMessage(CCTCPMessage& Message) { bool CIRCSock::OnErrorMessage(CMessage& Message) { // ERROR :Closing Link: nick[24.24.24.24] (Excess Flood) CString sError = Message.GetParam(0); - m_pNetwork->PutStatus("Error from Server [" + sError + "]"); + m_pNetwork->PutStatus(t_f("Error from server: {1}")(sError)); return true; } @@ -682,8 +682,8 @@ bool CIRCSock::OnNumericMessage(CNumericMessage& Message) { if (m_bAuthed && sServer == "irc.znc.in") { // m_bAuthed == true => we already received another 001 => we // might be in a traffic loop - m_pNetwork->PutStatus( - "ZNC seems to be connected to itself, disconnecting..."); + m_pNetwork->PutStatus(t_s( + "ZNC seems to be connected to itself, disconnecting...")); Quit(); return true; } @@ -730,11 +730,11 @@ bool CIRCSock::OnNumericMessage(CNumericMessage& Message) { CString sPort = Message.GetParam(2); CString sInfo = Message.GetParam(3); m_pNetwork->PutStatus( - "Server [" + m_pNetwork->GetCurrentServer()->GetString(false) + - "] redirects us to [" + sHost + ":" + sPort + - "] with reason [" + sInfo + "]"); + t_f("Server {1} redirects us to {2}:{3} with reason: {3}")( + m_pNetwork->GetCurrentServer()->GetString(false), sHost, + sPort, sInfo)); m_pNetwork->PutStatus( - "Perhaps you want to add it as a new server."); + t_s("Perhaps you want to add it as a new server.")); // Don't send server redirects to the client return true; } @@ -963,9 +963,9 @@ bool CIRCSock::OnNumericMessage(CNumericMessage& Message) { } if (pChan) { pChan->Disable(); - m_pNetwork->PutStatus("Channel [" + pChan->GetName() + - "] is linked to " - "another channel and was thus disabled."); + m_pNetwork->PutStatus( + t_f("Channel {1} is linked to another channel and was thus " + "disabled.")(pChan->GetName())); } break; } @@ -976,7 +976,7 @@ bool CIRCSock::OnNumericMessage(CNumericMessage& Message) { // TLS if (!GetSSL()) { StartTLS(); - m_pNetwork->PutStatus("Switched to SSL (STARTTLS)"); + m_pNetwork->PutStatus(t_s("Switched to SSL (STARTTLS)")); } return true; @@ -1029,7 +1029,7 @@ bool CIRCSock::OnQuitMessage(CQuitMessage& Message) { bool bIsVisible = false; if (Nick.NickEquals(GetNick())) { - m_pNetwork->PutStatus("You quit [" + Message.GetReason() + "]"); + m_pNetwork->PutStatus(t_f("You quit: {1}")(Message.GetReason())); // We don't call module hooks and we don't // forward this quit to clients (Some clients // disconnect if they receive such a QUIT) @@ -1235,7 +1235,7 @@ void CIRCSock::Disconnected() { if (!m_pNetwork->GetUser()->IsBeingDeleted() && m_pNetwork->GetIRCConnectEnabled() && m_pNetwork->GetServers().size() != 0) { - m_pNetwork->PutStatus("Disconnected from IRC. Reconnecting..."); + m_pNetwork->PutStatus(t_s("Disconnected from IRC. Reconnecting...")); } m_pNetwork->ClearRawBuffer(); m_pNetwork->ClearMotdBuffer(); @@ -1265,11 +1265,11 @@ void CIRCSock::SockError(int iErrno, const CString& sDescription) { DEBUG(GetSockName() << " == SockError(" << iErrno << " " << sError << ")"); if (!m_pNetwork->GetUser()->IsBeingDeleted()) { if (GetConState() != CST_OK) { - m_pNetwork->PutStatus("Cannot connect to IRC (" + sError + - "). Retrying..."); + m_pNetwork->PutStatus( + t_f("Cannot connect to IRC ({1}). Retrying...")(sError)); } else { - m_pNetwork->PutStatus("Disconnected from IRC (" + sError + - "). Reconnecting..."); + m_pNetwork->PutStatus( + t_f("Disconnected from IRC ({1}). Reconnecting...")(sError)); } #ifdef HAVE_LIBSSL if (iErrno == errnoBadSSLCert) { @@ -1299,9 +1299,8 @@ void CIRCSock::SockError(int iErrno, const CString& sDescription) { CString sSHA256 = GetSSLPeerFingerprint(); m_pNetwork->PutStatus("SHA-256: " + sSHA256); m_pNetwork->PutStatus( - "If you trust this certificate, do /znc " - "AddTrustedServerFingerprint " + - sSHA256); + t_f("If you trust this certificate, do /znc " + "AddTrustedServerFingerprint {1}")(sSHA256)); } } #endif @@ -1316,7 +1315,8 @@ void CIRCSock::SockError(int iErrno, const CString& sDescription) { void CIRCSock::Timeout() { DEBUG(GetSockName() << " == Timeout()"); if (!m_pNetwork->GetUser()->IsBeingDeleted()) { - m_pNetwork->PutStatus("IRC connection timed out. Reconnecting..."); + m_pNetwork->PutStatus( + t_s("IRC connection timed out. Reconnecting...")); } m_pNetwork->ClearRawBuffer(); m_pNetwork->ClearMotdBuffer(); @@ -1328,7 +1328,7 @@ void CIRCSock::Timeout() { void CIRCSock::ConnectionRefused() { DEBUG(GetSockName() << " == ConnectionRefused()"); if (!m_pNetwork->GetUser()->IsBeingDeleted()) { - m_pNetwork->PutStatus("Connection Refused. Reconnecting..."); + m_pNetwork->PutStatus(t_s("Connection Refused. Reconnecting...")); } m_pNetwork->ClearRawBuffer(); m_pNetwork->ClearMotdBuffer(); @@ -1336,7 +1336,7 @@ void CIRCSock::ConnectionRefused() { void CIRCSock::ReachedMaxBuffer() { DEBUG(GetSockName() << " == ReachedMaxBuffer()"); - m_pNetwork->PutStatus("Received a too long line from the IRC server!"); + m_pNetwork->PutStatus(t_s("Received a too long line from the IRC server!")); Quit(); } @@ -1440,7 +1440,7 @@ void CIRCSock::SendAltNick(const CString& sBadNick) { } else { char cLetter = 0; if (sBadNick.empty()) { - m_pNetwork->PutUser("No free nick available"); + m_pNetwork->PutUser(t_s("No free nick available")); Quit(); return; } @@ -1448,7 +1448,7 @@ void CIRCSock::SendAltNick(const CString& sBadNick) { cLetter = sBadNick.back(); if (cLetter == 'z') { - m_pNetwork->PutUser("No free nick found"); + m_pNetwork->PutUser(t_s("No free nick found")); Quit(); return; } diff --git a/src/Modules.cpp b/src/Modules.cpp index fbc0ac91..4b97cabb 100644 --- a/src/Modules.cpp +++ b/src/Modules.cpp @@ -525,8 +525,9 @@ bool CModule::AddCommand(const CString& sCmd, const COptionalTranslation& Args, } void CModule::AddHelpCommand() { - AddCommand("Help", &CModule::HandleHelpCommand, "search", - "Generate this output"); + AddCommand("Help", t_d("", "modhelpcmd"), + t_d("Generate this output", "modhelpcmd"), + [=](const CString& sLine) { HandleHelpCommand(sLine); }); } bool CModule::RemCommand(const CString& sCmd) { @@ -569,7 +570,7 @@ void CModule::HandleHelpCommand(const CString& sLine) { } } if (Table.empty()) { - PutModule("No matches for '" + sFilter + "'"); + PutModule(t_f("No matches for '{1}'")(sFilter)); } else { PutModule(Table); } @@ -687,9 +688,9 @@ void CModule::OnUnknownModCommand(const CString& sLine) { // This function is only called if OnModCommand wasn't // overriden, so no false warnings for modules which don't use // CModCommand for command handling. - PutModule("This module doesn't implement any commands."); + PutModule(t_s("This module doesn't implement any commands.")); else - PutModule("Unknown command!"); + PutModule(t_s("Unknown command!")); } void CModule::OnQuit(const CNick& Nick, const CString& sMessage, @@ -1629,7 +1630,7 @@ bool CModules::LoadModule(const CString& sModule, const CString& sArgs, sRetMsg = ""; if (FindModule(sModule) != nullptr) { - sRetMsg = "Module [" + sModule + "] already loaded."; + sRetMsg = t_f("Module {1} already loaded.")(sModule); return false; } @@ -1643,7 +1644,7 @@ bool CModules::LoadModule(const CString& sModule, const CString& sArgs, CModInfo Info; if (!FindModPath(sModule, sModPath, sDataPath)) { - sRetMsg = "Unable to find module [" + sModule + "]"; + sRetMsg = t_f("Unable to find module {1}")(sModule); return false; } Info.SetName(sModule); @@ -1655,20 +1656,20 @@ bool CModules::LoadModule(const CString& sModule, const CString& sArgs, if (!Info.SupportsType(eType)) { dlclose(p); - sRetMsg = "Module [" + sModule + "] does not support module type [" + - CModInfo::ModuleTypeToString(eType) + "]."; + sRetMsg = t_f("Module {1} does not support module type {1}.")( + sModule, CModInfo::ModuleTypeToString(eType)); return false; } if (!pUser && eType == CModInfo::UserModule) { dlclose(p); - sRetMsg = "Module [" + sModule + "] requires a user."; + sRetMsg = t_f("Module {1} requires a user.")(sModule); return false; } if (!pNetwork && eType == CModInfo::NetworkModule) { dlclose(p); - sRetMsg = "Module [" + sModule + "] requires a network."; + sRetMsg = t_f("Module {1} requires a network.")(sModule); return false; } @@ -1684,15 +1685,15 @@ bool CModules::LoadModule(const CString& sModule, const CString& sArgs, bLoaded = pModule->OnLoad(sArgs, sRetMsg); } catch (const CModule::EModException&) { bLoaded = false; - sRetMsg = "Caught an exception"; + sRetMsg = t_s("Caught an exception"); } if (!bLoaded) { UnloadModule(sModule, sModPath); if (!sRetMsg.empty()) - sRetMsg = "Module [" + sModule + "] aborted: " + sRetMsg; + sRetMsg = t_f("Module {1} aborted: {2}")(sModule, sRetMsg); else - sRetMsg = "Module [" + sModule + "] aborted."; + sRetMsg = t_f("Module {1} aborted.")(sModule); return false; } @@ -1716,7 +1717,7 @@ bool CModules::UnloadModule(const CString& sModule, CString& sRetMsg) { sRetMsg = ""; if (!pModule) { - sRetMsg = "Module [" + sMod + "] not loaded."; + sRetMsg = t_f("Module [{1}] not loaded.")(sMod); return false; } @@ -1740,12 +1741,12 @@ bool CModules::UnloadModule(const CString& sModule, CString& sRetMsg) { } dlclose(p); - sRetMsg = "Module [" + sMod + "] unloaded"; + sRetMsg = t_f("Module {1} unloaded.")(sMod); return true; } - sRetMsg = "Unable to unload module [" + sMod + "]"; + sRetMsg = t_f("Unable to unload module {1}.")(sMod); return false; } @@ -1758,7 +1759,7 @@ bool CModules::ReloadModule(const CString& sModule, const CString& sArgs, CModule* pModule = FindModule(sMod); if (!pModule) { - sRetMsg = "Module [" + sMod + "] not loaded"; + sRetMsg = t_f("Module [{1}] not loaded.")(sMod); return false; } @@ -1774,7 +1775,7 @@ bool CModules::ReloadModule(const CString& sModule, const CString& sArgs, return false; } - sRetMsg = "Reloaded module [" + sMod + "]"; + sRetMsg = t_f("Reloaded module {1}.")(sMod); return true; } @@ -1789,7 +1790,7 @@ bool CModules::GetModInfo(CModInfo& ModInfo, const CString& sModule, if (bHandled) return bSuccess; if (!FindModPath(sModule, sModPath, sTmp)) { - sRetMsg = "Unable to find module [" + sModule + "]"; + sRetMsg = t_f("Unable to find module {1}.")(sModule); return false; } @@ -1915,9 +1916,8 @@ ModHandle CModules::OpenModule(const CString& sModule, const CString& sModPath, ((sModule[a] < 'a') || (sModule[a] > 'z')) && ((sModule[a] < 'A') || (sModule[a] > 'Z')) && (sModule[a] != '_')) { sRetMsg = - "Module names can only contain letters, numbers and " - "underscores, [" + - sModule + "] is invalid."; + t_f("Module names can only contain letters, numbers and " + "underscores, [{1}] is invalid")(sModule); return nullptr; } } @@ -1940,8 +1940,8 @@ ModHandle CModules::OpenModule(const CString& sModule, const CString& sModPath, // dlerror() returns pointer to static buffer, which may be overwritten // very soon with another dl call also it may just return null. const char* cDlError = dlerror(); - CString sDlError = cDlError ? cDlError : "Unknown error"; - sRetMsg = "Unable to open module [" + sModule + "] [" + sDlError + "]"; + CString sDlError = cDlError ? cDlError : t_s("Unknown error"); + sRetMsg = t_f("Unable to open module {1}: {2}")(sModule, sDlError); return nullptr; } @@ -1950,30 +1950,28 @@ ModHandle CModules::OpenModule(const CString& sModule, const CString& sModPath, *reinterpret_cast(&fpZNCModuleEntry) = dlsym(p, "ZNCModuleEntry"); if (!fpZNCModuleEntry) { dlclose(p); - sRetMsg = "Could not find ZNCModuleEntry in module [" + sModule + "]"; + sRetMsg = t_f("Could not find ZNCModuleEntry in module {1}")(sModule); return nullptr; } const CModuleEntry* pModuleEntry = fpZNCModuleEntry(); if (std::strcmp(pModuleEntry->pcVersion, VERSION_STR) || std::strcmp(pModuleEntry->pcVersionExtra, VERSION_EXTRA)) { - sRetMsg = "Version mismatch for module [" + sModule + - "] (core is " VERSION_STR VERSION_EXTRA - ", module is built for " + - CString(pModuleEntry->pcVersion) + - pModuleEntry->pcVersionExtra + "), recompile this module."; + sRetMsg = t_f( + "Version mismatch for module {1}: core is {2}, module is built for " + "{3}. Recompile this module.")( + sModule, VERSION_STR VERSION_EXTRA, + CString(pModuleEntry->pcVersion) + pModuleEntry->pcVersionExtra); dlclose(p); return nullptr; } if (std::strcmp(pModuleEntry->pcCompileOptions, ZNC_COMPILE_OPTIONS_STRING)) { - sRetMsg = - "Module [" + sModule + - "] is built incompatibly (core is '" ZNC_COMPILE_OPTIONS_STRING - "', module is '" + - CString(pModuleEntry->pcCompileOptions) + - "'), recompile this module."; + sRetMsg = t_f( + "Module {1} is built incompatibly: core is '{2}', module is '{3}'. " + "Recompile this module.")(sModule, ZNC_COMPILE_OPTIONS_STRING, + pModuleEntry->pcCompileOptions); dlclose(p); return nullptr; } @@ -2001,14 +1999,14 @@ CModCommand::CModCommand(const CString& sCmd, CmdFunc func, : m_sCmd(sCmd), m_pFunc(std::move(func)), m_Args(Args), m_Desc(Desc) {} void CModCommand::InitHelp(CTable& Table) { - Table.AddColumn("Command"); - Table.AddColumn("Description"); + Table.AddColumn(t_s("Command", "modhelpcmd")); + Table.AddColumn(t_s("Description", "modhelpcmd")); } void CModCommand::AddHelp(CTable& Table) const { Table.AddRow(); - Table.SetCell("Command", GetCommand() + " " + GetArgs()); - Table.SetCell("Description", GetDescription()); + Table.SetCell(t_s("Command", "modhelpcmd"), GetCommand() + " " + GetArgs()); + Table.SetCell(t_s("Description", "modhelpcmd"), GetDescription()); } CString CModule::t_s(const CString& sEnglish, const CString& sContext) const { From fd15c4371172701687e6243267dbedb2e64c20e2 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Sun, 1 Apr 2018 00:37:06 +0100 Subject: [PATCH 12/20] Update date in comment about default SSL ciphers --- src/Socket.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Socket.cpp b/src/Socket.cpp index e17fdf1c..a15daed4 100644 --- a/src/Socket.cpp +++ b/src/Socket.cpp @@ -30,7 +30,7 @@ #ifdef HAVE_LIBSSL // Copypasted from // https://wiki.mozilla.org/Security/Server_Side_TLS#Intermediate_compatibility_.28default.29 -// at 2016-06-03 +// at 2018-04-01 static CString ZNC_DefaultCipher() { return "ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-" "ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-" From 1e23a36e1da749c21ba7a42cb033fb12dad719a5 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Sun, 1 Apr 2018 12:06:29 +0100 Subject: [PATCH 13/20] More translateable strings (#1354) --- include/znc/Socket.h | 3 ++- src/SSLVerifyHost.cpp | 10 +++++++--- src/Socket.cpp | 16 ++++++++++------ 3 files changed, 19 insertions(+), 10 deletions(-) diff --git a/include/znc/Socket.h b/include/znc/Socket.h index 3cddc461..a667b643 100644 --- a/include/znc/Socket.h +++ b/include/znc/Socket.h @@ -72,7 +72,8 @@ class CZNCSock : public Csock, public CCoreTranslationMixin { enum EAddrType { ADDR_IPV4ONLY, ADDR_IPV6ONLY, ADDR_ALL }; -class CSockManager : public TSocketManager { +class CSockManager : public TSocketManager, + private CCoreTranslationMixin { public: CSockManager(); virtual ~CSockManager(); diff --git a/src/SSLVerifyHost.cpp b/src/SSLVerifyHost.cpp index 95859e45..30d9487c 100644 --- a/src/SSLVerifyHost.cpp +++ b/src/SSLVerifyHost.cpp @@ -15,6 +15,7 @@ */ #include +#include #ifdef HAVE_LIBSSL #if defined(OPENSSL_VERSION_NUMBER) && !defined(LIBRESSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10100007 @@ -432,6 +433,9 @@ static HostnameValidationResult validate_hostname(const char* hostname, bool ZNC_SSLVerifyHost(const CString& sHost, const X509* pCert, CString& sError) { + struct Tr : CCoreTranslationMixin { + using CCoreTranslationMixin::t_s; + }; DEBUG("SSLVerifyHost: checking " << sHost); ZNC_iSECPartners::HostnameValidationResult eResult = ZNC_iSECPartners::validate_hostname(sHost.c_str(), pCert); @@ -441,15 +445,15 @@ bool ZNC_SSLVerifyHost(const CString& sHost, const X509* pCert, return true; case ZNC_iSECPartners::MatchNotFound: DEBUG("SSLVerifyHost: host doesn't match"); - sError = "hostname doesn't match"; + sError = Tr::t_s("hostname doesn't match"); return false; case ZNC_iSECPartners::MalformedCertificate: DEBUG("SSLVerifyHost: malformed cert"); - sError = "malformed hostname in certificate"; + sError = Tr::t_s("malformed hostname in certificate"); return false; default: DEBUG("SSLVerifyHost: error"); - sError = "hostname verification error"; + sError = Tr::t_s("hostname verification error"); return false; } } diff --git a/src/Socket.cpp b/src/Socket.cpp index a15daed4..fa510462 100644 --- a/src/Socket.cpp +++ b/src/Socket.cpp @@ -333,16 +333,19 @@ void CSockManager::SetTDNSThreadFinished(TDNSTask* task, bool bBind, try { if (ssTargets4.empty() && ssTargets6.empty()) { - throw "Can't resolve server hostname"; + throw t_s("Can't resolve server hostname"); } else if (task->sBindhost.empty()) { // Choose random target std::tie(sTargetHost, std::ignore) = RandomFrom2SetsWithBias(ssTargets4, ssTargets6, gen); } else if (ssBinds4.empty() && ssBinds6.empty()) { - throw "Can't resolve bind hostname. Try /znc ClearBindHost and /znc ClearUserBindHost"; + throw t_s( + "Can't resolve bind hostname. Try /znc ClearBindHost and /znc " + "ClearUserBindHost"); } else if (ssBinds4.empty()) { if (ssTargets6.empty()) { - throw "Server address is IPv4-only, but bindhost is IPv6-only"; + throw t_s( + "Server address is IPv4-only, but bindhost is IPv6-only"); } else { // Choose random target and bindhost from IPv6-only sets sTargetHost = RandomFromSet(ssTargets6, gen); @@ -350,7 +353,8 @@ void CSockManager::SetTDNSThreadFinished(TDNSTask* task, bool bBind, } } else if (ssBinds6.empty()) { if (ssTargets4.empty()) { - throw "Server address is IPv6-only, but bindhost is IPv4-only"; + throw t_s( + "Server address is IPv6-only, but bindhost is IPv4-only"); } else { // Choose random target and bindhost from IPv4-only sets sTargetHost = RandomFromSet(ssTargets4, gen); @@ -370,7 +374,7 @@ void CSockManager::SetTDNSThreadFinished(TDNSTask* task, bool bBind, << "] using bindhost [" << sBindhost << "]"); FinishConnect(sTargetHost, task->iPort, task->sSockName, task->iTimeout, task->bSSL, sBindhost, task->pcSock); - } catch (const char* s) { + } catch (const CString& s) { DEBUG(task->sSockName << ", dns resolving error: " << s); task->pcSock->SetSockName(task->sSockName); task->pcSock->SockError(-1, s); @@ -508,7 +512,7 @@ void CSocket::ReachedMaxBuffer() { DEBUG(GetSockName() << " == ReachedMaxBuffer()"); if (m_pModule) m_pModule->PutModule( - "Some socket reached its max buffer limit and was closed!"); + t_s("Some socket reached its max buffer limit and was closed!")); Close(); } From 10c98e01a8cfe10abc1d33c865e0f941cf7222f8 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Sun, 1 Apr 2018 12:23:16 +0100 Subject: [PATCH 14/20] Why did I make this public? --- include/znc/Socket.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/znc/Socket.h b/include/znc/Socket.h index a667b643..2eceda6f 100644 --- a/include/znc/Socket.h +++ b/include/znc/Socket.h @@ -24,7 +24,7 @@ class CModule; -class CZNCSock : public Csock, public CCoreTranslationMixin { +class CZNCSock : public Csock, protected CCoreTranslationMixin { public: CZNCSock(int timeout = 60); CZNCSock(const CString& sHost, u_short port, int timeout = 60); From 1e08e5c702935bede7ccda2115739b6b1eaad4dc Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 2 Apr 2018 12:16:36 +0100 Subject: [PATCH 15/20] Move gtest's printer for CString to a place visible to all tests --- include/znc/ZNCString.h | 7 +++++++ test/StringTest.cpp | 5 ----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/include/znc/ZNCString.h b/include/znc/ZNCString.h index 30bdcd8a..ae1a647b 100644 --- a/include/znc/ZNCString.h +++ b/include/znc/ZNCString.h @@ -697,4 +697,11 @@ class CInlineFormatMessage { CString m_sFormat; }; +// For gtest +#ifdef GTEST_FAIL +inline void PrintTo(const CString& s, std::ostream* os) { + *os << '"' << s.Escape_n(CString::EDEBUG) << '"'; +} +#endif + #endif // !ZNCSTRING_H diff --git a/test/StringTest.cpp b/test/StringTest.cpp index a675a3f7..0e99caef 100644 --- a/test/StringTest.cpp +++ b/test/StringTest.cpp @@ -17,11 +17,6 @@ #include #include -// GTest uses this function to output objects -static void PrintTo(const CString& s, std::ostream* o) { - *o << '"' << s.Escape_n(CString::EASCII, CString::EDEBUG) << '"'; -} - class EscapeTest : public ::testing::Test { protected: void testEncode(const CString& in, const CString& expectedOut, From f3ddbccedd2526cfae64a3e34fb6e46295988f5c Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 2 Apr 2018 12:19:01 +0100 Subject: [PATCH 16/20] Fix unit test after string changes --- test/IRCSockTest.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/IRCSockTest.cpp b/test/IRCSockTest.cpp index 3a116ed4..023cc226 100644 --- a/test/IRCSockTest.cpp +++ b/test/IRCSockTest.cpp @@ -211,7 +211,7 @@ TEST_F(IRCSockTest, OnErrorMessage) { EXPECT_THAT( m_pTestClient->vsLines, ElementsAre( - ":*status!znc@znc.in PRIVMSG me :Error from Server [foo bar]")); + ":*status!znc@znc.in PRIVMSG me :Error from server: foo bar")); } TEST_F(IRCSockTest, OnInviteMessage) { From 9de990715b25b6b113b9cd270b408145072e059a Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Tue, 3 Apr 2018 22:30:18 +0100 Subject: [PATCH 17/20] More translateable strings (fix #1354) --- include/znc/User.h | 3 ++- include/znc/znc.h | 4 +++- src/User.cpp | 22 +++++++++++----------- src/znc.cpp | 22 +++++++++++----------- 4 files changed, 27 insertions(+), 24 deletions(-) diff --git a/include/znc/User.h b/include/znc/User.h index 3d87f38d..0f8eb351 100644 --- a/include/znc/User.h +++ b/include/znc/User.h @@ -21,6 +21,7 @@ #include #include #include +#include #include #include @@ -34,7 +35,7 @@ class CIRCSock; class CUserTimer; class CServer; -class CUser { +class CUser : private CCoreTranslationMixin { public: CUser(const CString& sUserName); ~CUser(); diff --git a/include/znc/znc.h b/include/znc/znc.h index 97148c6c..ecb2b41a 100644 --- a/include/znc/znc.h +++ b/include/znc/znc.h @@ -35,7 +35,7 @@ class CConfigWriteTimer; class CConfig; class CFile; -class CZNC { +class CZNC : private CCoreTranslationMixin { public: CZNC(); ~CZNC(); @@ -253,6 +253,8 @@ class CZNC { static void DumpConfig(const CConfig* Config); private: + static CString FormatBindError(); + CFile* InitPidFile(); bool ReadConfig(CConfig& config, CString& sError); diff --git a/src/User.cpp b/src/User.cpp index b8cf4615..3a18a5f0 100644 --- a/src/User.cpp +++ b/src/User.cpp @@ -504,11 +504,11 @@ bool CUser::ParseConfig(CConfig* pConfig, CString& sError) { CIRCNetwork* CUser::AddNetwork(const CString& sNetwork, CString& sErrorRet) { if (!CIRCNetwork::IsValidNetwork(sNetwork)) { sErrorRet = - "Invalid network name. It should be alphanumeric. Not to be " - "confused with server name"; + t_s("Invalid network name. It should be alphanumeric. Not to be " + "confused with server name"); return nullptr; } else if (FindNetwork(sNetwork)) { - sErrorRet = "Network [" + sNetwork.Token(0) + "] already exists"; + sErrorRet = t_f("Network {1} already exists")(sNetwork); return nullptr; } @@ -674,8 +674,8 @@ void CUser::UserConnected(CClient* pClient) { BounceAllClients(); } - pClient->PutClient(":irc.znc.in 001 " + pClient->GetNick() + - " :- Welcome to ZNC -"); + pClient->PutClient(":irc.znc.in 001 " + pClient->GetNick() + " :" + + t_s("Welcome to ZNC")); m_vClients.push_back(pClient); } @@ -774,8 +774,8 @@ bool CUser::Clone(const CUser& User, CString& sErrorRet, bool bCloneNetworks) { for (CClient* pSock : m_vClients) { if (!IsHostAllowed(pSock->GetRemoteIP())) { pSock->PutStatusNotice( - "You are being disconnected because your IP is no longer " - "allowed to connect to this user"); + t_s("You are being disconnected because your IP is no longer " + "allowed to connect to this user")); pSock->Close(); } } @@ -904,17 +904,17 @@ bool CUser::IsValid(CString& sErrMsg, bool bSkipPass) const { sErrMsg.clear(); if (!bSkipPass && m_sPass.empty()) { - sErrMsg = "Pass is empty"; + sErrMsg = t_s("Password is empty"); return false; } if (m_sUserName.empty()) { - sErrMsg = "Username is empty"; + sErrMsg = t_s("Username is empty"); return false; } if (!CUser::IsValidUserName(m_sUserName)) { - sErrMsg = "Username is invalid"; + sErrMsg = t_s("Username is invalid"); return false; } @@ -1185,7 +1185,7 @@ bool CUser::LoadModule(const CString& sModName, const CString& sArgs, CModInfo ModInfo; if (!CZNC::Get().GetModules().GetModInfo(ModInfo, sModName, sModRet)) { - sError = "Unable to find modinfo [" + sModName + "] [" + sModRet + "]"; + sError = t_f("Unable to find modinfo {1}: {2}")(sModName, sModRet); return false; } diff --git a/src/znc.cpp b/src/znc.cpp index 8e3ba615..4e7216ee 100644 --- a/src/znc.cpp +++ b/src/znc.cpp @@ -34,12 +34,6 @@ using std::list; using std::tuple; using std::make_tuple; -static inline CString FormatBindError() { - CString sError = (errno == 0 ? CString("unknown error, check the host name") - : CString(strerror(errno))); - return "Unable to bind [" + sError + "]"; -} - CZNC::CZNC() : m_TimeStarted(time(nullptr)), m_eConfigState(ECONFIG_NOTHING), @@ -1566,7 +1560,7 @@ bool CZNC::DeleteUser(const CString& sUsername) { bool CZNC::AddUser(CUser* pUser, CString& sErrorRet, bool bStartup) { if (FindUser(pUser->GetUserName()) != nullptr) { - sErrorRet = "User already exists"; + sErrorRet = t_s("User already exists"); DEBUG("User [" << pUser->GetUserName() << "] - already exists"); return false; } @@ -1674,7 +1668,7 @@ bool CZNC::AddListener(unsigned short uPort, const CString& sBindHost, #ifndef HAVE_IPV6 if (ADDR_IPV6ONLY == eAddr) { - sError = "IPV6 is not enabled"; + sError = t_s("IPv6 is not enabled"); CUtils::PrintStatus(false, sError); return false; } @@ -1682,7 +1676,7 @@ bool CZNC::AddListener(unsigned short uPort, const CString& sBindHost, #ifndef HAVE_LIBSSL if (bSSL) { - sError = "SSL is not enabled"; + sError = t_s("SSL is not enabled"); CUtils::PrintStatus(false, sError); return false; } @@ -1690,7 +1684,7 @@ bool CZNC::AddListener(unsigned short uPort, const CString& sBindHost, CString sPemFile = GetPemLocation(); if (bSSL && !CFile::Exists(sPemFile)) { - sError = "Unable to locate pem file: [" + sPemFile + "]"; + sError = t_f("Unable to locate pem file: {1}")(sPemFile); CUtils::PrintStatus(false, sError); // If stdin is e.g. /dev/null and we call GetBoolInput(), @@ -1709,7 +1703,7 @@ bool CZNC::AddListener(unsigned short uPort, const CString& sBindHost, } #endif if (!uPort) { - sError = "Invalid port"; + sError = t_s("Invalid port"); CUtils::PrintStatus(false, sError); return false; } @@ -1822,6 +1816,12 @@ bool CZNC::DelListener(CListener* pListener) { return false; } +CString CZNC::FormatBindError() { + CString sError = (errno == 0 ? t_s(("unknown error, check the host name")) + : CString(strerror(errno))); + return t_f("Unable to bind: {1}")(sError); +} + static CZNC* s_pZNC = nullptr; void CZNC::CreateInstance() { From c6a04023a4e79f54653562ad25f70bd741e5fef7 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Wed, 4 Apr 2018 01:21:09 +0100 Subject: [PATCH 18/20] Reformat test --- test/integration/tests/scripting.cpp | 68 ++++++++++++++-------------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/test/integration/tests/scripting.cpp b/test/integration/tests/scripting.cpp index 213d15a4..304b88f9 100644 --- a/test/integration/tests/scripting.cpp +++ b/test/integration/tests/scripting.cpp @@ -104,45 +104,45 @@ TEST_F(ZNCTest, ModperlSocket) { "DISABLED_ZNC_PERL_PYTHON_TEST") == "1") { return; } - auto znc = Run(); - znc->CanLeak(); + auto znc = Run(); + znc->CanLeak(); - InstallModule("socktest.pm", R"( - package socktest::acc; - use base 'ZNC::Socket'; - sub OnReadData { - my ($self, $data, $len) = @_; - $self->GetModule->PutModule("received $len bytes"); - $self->Close; - } + InstallModule("socktest.pm", R"( + package socktest::acc; + use base 'ZNC::Socket'; + sub OnReadData { + my ($self, $data, $len) = @_; + $self->GetModule->PutModule("received $len bytes"); + $self->Close; + } - package socktest::lis; - use base 'ZNC::Socket'; - sub OnAccepted { - my $self = shift; - return $self->GetModule->CreateSocket('socktest::acc'); - } + package socktest::lis; + use base 'ZNC::Socket'; + sub OnAccepted { + my $self = shift; + return $self->GetModule->CreateSocket('socktest::acc'); + } - package socktest::conn; - use base 'ZNC::Socket'; + package socktest::conn; + use base 'ZNC::Socket'; - package socktest; - use base 'ZNC::Module'; - sub OnLoad { - my $self = shift; - my $listen = $self->CreateSocket('socktest::lis'); - $self->{port} = $listen->Listen; - return 1; - } - sub OnModCommand { - my ($self, $cmd) = @_; - my $sock = $self->CreateSocket('socktest::conn'); - $sock->Connect('127.0.0.1', $self->{port}); - $sock->Write('blah'); - } + package socktest; + use base 'ZNC::Module'; + sub OnLoad { + my $self = shift; + my $listen = $self->CreateSocket('socktest::lis'); + $self->{port} = $listen->Listen; + return 1; + } + sub OnModCommand { + my ($self, $cmd) = @_; + my $sock = $self->CreateSocket('socktest::conn'); + $sock->Connect('127.0.0.1', $self->{port}); + $sock->Write('blah'); + } - 1; - )"); + 1; + )"); auto ircd = ConnectIRCd(); auto client = LoginClient(); From b9743d832025b6cff1f210d4128815b51e8b9ed9 Mon Sep 17 00:00:00 2001 From: ZNC-Jenkins bot Date: Wed, 4 Apr 2018 01:40:11 +0100 Subject: [PATCH 19/20] Update translations from Crowdin (#1502) --- modules/po/block_motd.ru.po | 4 +- modules/po/dcc.ru.po | 67 ++--- modules/po/kickrejoin.ru.po | 2 +- modules/po/listsockets.ru.po | 46 ++-- modules/po/send_raw.ru.po | 47 ++-- modules/po/shell.ru.po | 7 +- modules/po/webadmin.ru.po | 16 +- src/po/znc.de.po | 422 +++++++++++++++++++++++++++-- src/po/znc.pot | 422 +++++++++++++++++++++++++++-- src/po/znc.ru.po | 508 ++++++++++++++++++++++++++++++----- 10 files changed, 1334 insertions(+), 207 deletions(-) diff --git a/modules/po/block_motd.ru.po b/modules/po/block_motd.ru.po index 095efc9b..62d9f43b 100644 --- a/modules/po/block_motd.ru.po +++ b/modules/po/block_motd.ru.po @@ -16,7 +16,7 @@ msgstr "" #: block_motd.cpp:26 msgid "[]" -msgstr "" +msgstr "[]" #: block_motd.cpp:27 msgid "" @@ -30,7 +30,7 @@ msgstr "" #: block_motd.cpp:58 msgid "MOTD blocked by ZNC" -msgstr "" +msgstr "MOTD блокирован ZNC" #: block_motd.cpp:104 msgid "Block the MOTD from IRC so it's not sent to your client(s)." diff --git a/modules/po/dcc.ru.po b/modules/po/dcc.ru.po index 91afbd5e..70ec39a4 100644 --- a/modules/po/dcc.ru.po +++ b/modules/po/dcc.ru.po @@ -16,149 +16,150 @@ msgstr "" #: dcc.cpp:88 msgid " " -msgstr "" +msgstr " " #: dcc.cpp:89 msgid "Send a file from ZNC to someone" -msgstr "" +msgstr "Отправить файл из ZNC кому-либо" #: dcc.cpp:91 msgid "" -msgstr "" +msgstr "" #: dcc.cpp:92 msgid "Send a file from ZNC to your client" -msgstr "" +msgstr "Отправить файл из ZNC на ваш клиент" #: dcc.cpp:94 msgid "List current transfers" -msgstr "" +msgstr "Список текущих передач" #: dcc.cpp:103 msgid "You must be admin to use the DCC module" -msgstr "" +msgstr "Вы должны быть администратором для использования модуля DCC" #: dcc.cpp:140 msgid "Attempting to send [{1}] to [{2}]." -msgstr "" +msgstr "Попытка отправить [{1}] [{2}]." #: dcc.cpp:149 dcc.cpp:554 msgid "Receiving [{1}] from [{2}]: File already exists." -msgstr "" +msgstr "Получение [{1}] с [{2}]: файл уже существует." #: dcc.cpp:167 msgid "" "Attempting to connect to [{1} {2}] in order to download [{3}] from [{4}]." -msgstr "" +msgstr "Попытка подключиться к [{1} {2}], чтобы загрузить [{3}] с [{4}]." #: dcc.cpp:179 msgid "Usage: Send " -msgstr "" +msgstr "Использование: Send " #: dcc.cpp:186 dcc.cpp:206 msgid "Illegal path." -msgstr "" +msgstr "Некорректные пути." #: dcc.cpp:199 msgid "Usage: Get " -msgstr "" +msgstr "Использование: Get " #: dcc.cpp:215 dcc.cpp:232 dcc.cpp:234 msgctxt "list" msgid "Type" -msgstr "" +msgstr "Тип" #: dcc.cpp:216 dcc.cpp:238 dcc.cpp:241 msgctxt "list" msgid "State" -msgstr "" +msgstr "Состояние" #: dcc.cpp:217 dcc.cpp:243 msgctxt "list" msgid "Speed" -msgstr "" +msgstr "Скорость" #: dcc.cpp:218 dcc.cpp:227 msgctxt "list" msgid "Nick" -msgstr "" +msgstr "Ник" #: dcc.cpp:219 dcc.cpp:228 msgctxt "list" msgid "IP" -msgstr "" +msgstr "IP" #: dcc.cpp:220 dcc.cpp:229 msgctxt "list" msgid "File" -msgstr "" +msgstr "Файл" #: dcc.cpp:232 msgctxt "list-type" msgid "Sending" -msgstr "" +msgstr "Отправка" #: dcc.cpp:234 msgctxt "list-type" msgid "Getting" -msgstr "" +msgstr "Получение" #: dcc.cpp:239 msgctxt "list-state" msgid "Waiting" -msgstr "" +msgstr "Ожидание" #: dcc.cpp:244 msgid "{1} KiB/s" -msgstr "" +msgstr "{1} Кб/сек" #: dcc.cpp:250 msgid "You have no active DCC transfers." -msgstr "" +msgstr "У вас нет активных передач DCC." #: dcc.cpp:267 msgid "Attempting to resume send from position {1} of file [{2}] for [{3}]" -msgstr "" +msgstr "Попытка возобновить отправку от позиции {1} файла [{2}] на [{3}]" #: dcc.cpp:277 msgid "Couldn't resume file [{1}] for [{2}]: not sending anything." msgstr "" +"Не удалось возобновить отправку файла [{1}] [{2}]: не отправлено ничего." #: dcc.cpp:286 msgid "Bad DCC file: {1}" -msgstr "" +msgstr "Плохой файл DCC: {1}" #: dcc.cpp:341 msgid "Sending [{1}] to [{2}]: File not open!" -msgstr "" +msgstr "Отправка [{1}] [{2}]: файл не открыт!" #: dcc.cpp:345 msgid "Receiving [{1}] from [{2}]: File not open!" -msgstr "" +msgstr "Получение [{1}] с [{2}]: файл не открыт!" #: dcc.cpp:385 msgid "Sending [{1}] to [{2}]: Connection refused." -msgstr "" +msgstr "Отправка [{1}] [{2}]: Отказанное соединение." #: dcc.cpp:389 msgid "Receiving [{1}] from [{2}]: Connection refused." -msgstr "" +msgstr "Получение [{1}] с [{2}]: Отказанное соединение." #: dcc.cpp:397 msgid "Sending [{1}] to [{2}]: Timeout." -msgstr "" +msgstr "Отправка [{1}] с [{2}]: время ожидания истекло." #: dcc.cpp:401 msgid "Receiving [{1}] from [{2}]: Timeout." -msgstr "" +msgstr "Получение[{1}] с [{2}]: время ожидания истекло." #: dcc.cpp:411 msgid "Sending [{1}] to [{2}]: Socket error {3}: {4}" -msgstr "" +msgstr "Отправка [{1}] [{2}]: ошибка сокета {3}: {4}" #: dcc.cpp:415 msgid "Receiving [{1}] from [{2}]: Socket error {3}: {4}" -msgstr "" +msgstr "Получение [{1}] с [{2}]: ошибка сокета {3}: {4}" #: dcc.cpp:423 msgid "Sending [{1}] to [{2}]: Transfer started." diff --git a/modules/po/kickrejoin.ru.po b/modules/po/kickrejoin.ru.po index 126aa39d..10af8f45 100644 --- a/modules/po/kickrejoin.ru.po +++ b/modules/po/kickrejoin.ru.po @@ -16,7 +16,7 @@ msgstr "" #: kickrejoin.cpp:56 msgid "" -msgstr "" +msgstr "" #: kickrejoin.cpp:56 msgid "Set the rejoin delay" diff --git a/modules/po/listsockets.ru.po b/modules/po/listsockets.ru.po index 67d51db8..29dfa0a7 100644 --- a/modules/po/listsockets.ru.po +++ b/modules/po/listsockets.ru.po @@ -17,99 +17,99 @@ msgstr "" #: modules/po/../data/listsockets/tmpl/index.tmpl:7 listsockets.cpp:214 #: listsockets.cpp:230 msgid "Name" -msgstr "" +msgstr "Имя" #: modules/po/../data/listsockets/tmpl/index.tmpl:8 listsockets.cpp:215 #: listsockets.cpp:231 msgid "Created" -msgstr "" +msgstr "Создан" #: modules/po/../data/listsockets/tmpl/index.tmpl:9 listsockets.cpp:216 #: listsockets.cpp:232 msgid "State" -msgstr "" +msgstr "Состояние" #: modules/po/../data/listsockets/tmpl/index.tmpl:10 listsockets.cpp:218 #: listsockets.cpp:235 msgid "SSL" -msgstr "" +msgstr "SSL" #: modules/po/../data/listsockets/tmpl/index.tmpl:11 listsockets.cpp:220 #: listsockets.cpp:240 msgid "Local" -msgstr "" +msgstr "Локальное" #: modules/po/../data/listsockets/tmpl/index.tmpl:12 listsockets.cpp:221 #: listsockets.cpp:242 msgid "Remote" -msgstr "" +msgstr "Удаленное" #: modules/po/../data/listsockets/tmpl/index.tmpl:13 msgid "Data In" -msgstr "" +msgstr "Входящий трафик" #: modules/po/../data/listsockets/tmpl/index.tmpl:14 msgid "Data Out" -msgstr "" +msgstr "Исходящий трафик" #: listsockets.cpp:62 msgid "[-n]" -msgstr "" +msgstr "[-n]" #: listsockets.cpp:62 msgid "Shows the list of active sockets. Pass -n to show IP addresses" -msgstr "" +msgstr "Показать список активных сокетов. Укажите -n для показа IP-адресов" #: listsockets.cpp:70 msgid "You must be admin to use this module" -msgstr "" +msgstr "Вы должны быть администратором для использования этого модуля" #: listsockets.cpp:96 msgid "List sockets" -msgstr "" +msgstr "Список сокетов" #: listsockets.cpp:116 listsockets.cpp:236 msgctxt "ssl" msgid "Yes" -msgstr "" +msgstr "Да" #: listsockets.cpp:116 listsockets.cpp:237 msgctxt "ssl" msgid "No" -msgstr "" +msgstr "Нет" #: listsockets.cpp:142 msgid "Listener" -msgstr "" +msgstr "Слушатель" #: listsockets.cpp:144 msgid "Inbound" -msgstr "" +msgstr "Входящие" #: listsockets.cpp:147 msgid "Outbound" -msgstr "" +msgstr "Исходящие" #: listsockets.cpp:149 msgid "Connecting" -msgstr "" +msgstr "Подключение…" #: listsockets.cpp:152 msgid "UNKNOWN" -msgstr "" +msgstr "НЕИЗВЕСТНО" #: listsockets.cpp:207 msgid "You have no open sockets." -msgstr "" +msgstr "У вас нет открытых сокетов." #: listsockets.cpp:222 listsockets.cpp:244 msgid "In" -msgstr "" +msgstr "Входящие данные" #: listsockets.cpp:223 listsockets.cpp:246 msgid "Out" -msgstr "" +msgstr "Исходящие данные" #: listsockets.cpp:262 msgid "Lists active sockets" -msgstr "" +msgstr "Список активных сокетов" diff --git a/modules/po/send_raw.ru.po b/modules/po/send_raw.ru.po index 663df4ba..e40b35d9 100644 --- a/modules/po/send_raw.ru.po +++ b/modules/po/send_raw.ru.po @@ -16,96 +16,97 @@ msgstr "" #: modules/po/../data/send_raw/tmpl/index.tmpl:9 msgid "Send a raw IRC line" -msgstr "" +msgstr "Отправить сырую строку IRC" #: modules/po/../data/send_raw/tmpl/index.tmpl:14 msgid "User:" -msgstr "" +msgstr "Пользователь:" #: modules/po/../data/send_raw/tmpl/index.tmpl:15 msgid "To change user, click to Network selector" -msgstr "" +msgstr "Чтобы изменить пользователя, щелкните на селектор сети" #: modules/po/../data/send_raw/tmpl/index.tmpl:19 msgid "User/Network:" -msgstr "" +msgstr "Пользователь/сеть:" #: modules/po/../data/send_raw/tmpl/index.tmpl:32 msgid "Send to:" -msgstr "" +msgstr "Отправить:" #: modules/po/../data/send_raw/tmpl/index.tmpl:34 msgid "Client" -msgstr "" +msgstr "Клиент" #: modules/po/../data/send_raw/tmpl/index.tmpl:35 msgid "Server" -msgstr "" +msgstr "Сервер" #: modules/po/../data/send_raw/tmpl/index.tmpl:40 msgid "Line:" -msgstr "" +msgstr "Строка:" #: modules/po/../data/send_raw/tmpl/index.tmpl:45 msgid "Send" -msgstr "" +msgstr "Отправить" #: send_raw.cpp:32 msgid "Sent [{1}] to {2}/{3}" -msgstr "" +msgstr "Отправил [{1}] {2}/{3}" #: send_raw.cpp:36 send_raw.cpp:56 msgid "Network {1} not found for user {2}" -msgstr "" +msgstr "Сеть {1} не найдена для пользователя {2}" #: send_raw.cpp:40 send_raw.cpp:60 msgid "User {1} not found" -msgstr "" +msgstr "Пользователь {1} не найден" #: send_raw.cpp:52 msgid "Sent [{1}] to IRC server of {2}/{3}" -msgstr "" +msgstr "Послал [{1}] к IRC серверу {2}/{3}" #: send_raw.cpp:75 msgid "You must have admin privileges to load this module" -msgstr "" +msgstr "Вы должны иметь привилегии администратора для загрузки этого модуля" #: send_raw.cpp:82 msgid "Send Raw" -msgstr "" +msgstr "Отправить сырым" #: send_raw.cpp:92 msgid "User not found" -msgstr "" +msgstr "Пользователь не найден" #: send_raw.cpp:99 msgid "Network not found" -msgstr "" +msgstr "Сеть не найдена" #: send_raw.cpp:116 msgid "Line sent" -msgstr "" +msgstr "Строка отправлена" #: send_raw.cpp:140 send_raw.cpp:143 msgid "[user] [network] [data to send]" -msgstr "" +msgstr "[user] [network] [данные для отправки]" #: send_raw.cpp:141 msgid "The data will be sent to the user's IRC client(s)" -msgstr "" +msgstr "Данные будут отправлены IRC-клиент(ам) этого пользователя" #: send_raw.cpp:144 msgid "The data will be sent to the IRC server the user is connected to" msgstr "" +"Данные будут передаваться на IRC-сервер, если пользователь подключен к нему" #: send_raw.cpp:147 msgid "[data to send]" -msgstr "" +msgstr "[данные для отправки]" #: send_raw.cpp:148 msgid "The data will be sent to your current client" -msgstr "" +msgstr "Данные будут отправлены на ваш текущий клиент" #: send_raw.cpp:159 msgid "Lets you send some raw IRC lines as/to someone else" -msgstr "" +msgstr "Позволяет отправлять некоторые сырые строки IRC кому-либо" diff --git a/modules/po/shell.ru.po b/modules/po/shell.ru.po index 5dd528c2..14071c52 100644 --- a/modules/po/shell.ru.po +++ b/modules/po/shell.ru.po @@ -16,16 +16,17 @@ msgstr "" #: shell.cpp:37 msgid "Failed to execute: {1}" -msgstr "" +msgstr "Не удалось выполнить: {1}" #: shell.cpp:75 msgid "You must be admin to use the shell module" -msgstr "" +msgstr "Вы должны быть администратором для использования модуля shell" #: shell.cpp:169 msgid "Gives shell access" -msgstr "" +msgstr "Дает доступ к оболочке" #: shell.cpp:172 msgid "Gives shell access. Only ZNC admins can use it." msgstr "" +"Дает доступ к оболочке. Только администраторы ZNC могут использовать это." diff --git a/modules/po/webadmin.ru.po b/modules/po/webadmin.ru.po index a6fa6468..f5914f6d 100644 --- a/modules/po/webadmin.ru.po +++ b/modules/po/webadmin.ru.po @@ -232,7 +232,7 @@ msgstr "Порт" #: modules/po/../data/webadmin/tmpl/add_edit_network.tmpl:103 #: modules/po/../data/webadmin/tmpl/settings.tmpl:15 msgid "SSL" -msgstr "" +msgstr "SSL" #: modules/po/../data/webadmin/tmpl/add_edit_network.tmpl:104 msgid "Password" @@ -658,7 +658,7 @@ msgstr "" #: modules/po/../data/webadmin/tmpl/add_edit_user.tmpl:322 msgid "Timeout before reconnect:" -msgstr "" +msgstr "Время ожидания до повторного подключения:" #: modules/po/../data/webadmin/tmpl/add_edit_user.tmpl:324 msgid "" @@ -837,19 +837,19 @@ msgstr "Хост" #: modules/po/../data/webadmin/tmpl/settings.tmpl:16 msgid "IPv4" -msgstr "" +msgstr "IPv4" #: modules/po/../data/webadmin/tmpl/settings.tmpl:17 msgid "IPv6" -msgstr "" +msgstr "IPv6" #: modules/po/../data/webadmin/tmpl/settings.tmpl:18 msgid "IRC" -msgstr "" +msgstr "IRC" #: modules/po/../data/webadmin/tmpl/settings.tmpl:19 msgid "HTTP" -msgstr "" +msgstr "HTTP" #: modules/po/../data/webadmin/tmpl/settings.tmpl:20 msgid "URIPrefix" @@ -941,7 +941,7 @@ msgstr "" #: modules/po/../data/webadmin/tmpl/settings.tmpl:158 msgid "MOTD:" -msgstr "" +msgstr "MOTD:" #: modules/po/../data/webadmin/tmpl/settings.tmpl:162 msgid "“Message of the Day”, sent to all ZNC users on connect." @@ -1054,7 +1054,7 @@ msgstr "Ошибка: пароли не совпадают" #: webadmin.cpp:323 msgid "Timeout can't be less than 30 seconds!" -msgstr "" +msgstr "Время ожидания не может быть меньше 30 секунд!" #: webadmin.cpp:407 webadmin.cpp:435 webadmin.cpp:1189 webadmin.cpp:2064 msgid "Unable to load module [{1}]: {2}" diff --git a/src/po/znc.de.po b/src/po/znc.de.po index c88f3cd4..aec9b13a 100644 --- a/src/po/znc.de.po +++ b/src/po/znc.de.po @@ -55,6 +55,226 @@ msgstr "" "code>\"). Sobald einige Web-fähige Module geladen wurden, wird das Menü " "größer." +#: znc.cpp:1563 +msgid "User already exists" +msgstr "" + +#: znc.cpp:1671 +msgid "IPv6 is not enabled" +msgstr "" + +#: znc.cpp:1679 +msgid "SSL is not enabled" +msgstr "" + +#: znc.cpp:1687 +msgid "Unable to locate pem file: {1}" +msgstr "" + +#: znc.cpp:1706 +msgid "Invalid port" +msgstr "" + +#: znc.cpp:1822 ClientCommand.cpp:1629 +msgid "Unable to bind: {1}" +msgstr "" + +#: IRCNetwork.cpp:236 +msgid "Jumping servers because this server is no longer in the list" +msgstr "" + +#: IRCNetwork.cpp:641 User.cpp:678 +msgid "Welcome to ZNC" +msgstr "" + +#: IRCNetwork.cpp:729 +msgid "You are currently disconnected from IRC. Use 'connect' to reconnect." +msgstr "" + +#: IRCNetwork.cpp:734 +msgid "" +"ZNC is presently running in DEBUG mode. Sensitive data during your current " +"session may be exposed to the host." +msgstr "" + +#: IRCNetwork.cpp:765 +msgid "This network is being deleted or moved to another user." +msgstr "" + +#: IRCNetwork.cpp:994 +msgid "The channel {1} could not be joined, disabling it." +msgstr "" + +#: IRCNetwork.cpp:1123 +msgid "Your current server was removed, jumping..." +msgstr "" + +#: IRCNetwork.cpp:1286 +msgid "Cannot connect to {1}, because ZNC is not compiled with SSL support." +msgstr "" + +#: IRCNetwork.cpp:1307 +msgid "Some module aborted the connection attempt" +msgstr "" + +#: IRCSock.cpp:484 +msgid "Error from server: {1}" +msgstr "" + +#: IRCSock.cpp:686 +msgid "ZNC seems to be connected to itself, disconnecting..." +msgstr "" + +#: IRCSock.cpp:733 +msgid "Server {1} redirects us to {2}:{3} with reason: {3}" +msgstr "" + +#: IRCSock.cpp:737 +msgid "Perhaps you want to add it as a new server." +msgstr "" + +#: IRCSock.cpp:967 +msgid "Channel {1} is linked to another channel and was thus disabled." +msgstr "" + +#: IRCSock.cpp:979 +msgid "Switched to SSL (STARTTLS)" +msgstr "" + +#: IRCSock.cpp:1032 +msgid "You quit: {1}" +msgstr "" + +#: IRCSock.cpp:1238 +msgid "Disconnected from IRC. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1269 +msgid "Cannot connect to IRC ({1}). Retrying..." +msgstr "" + +#: IRCSock.cpp:1272 +msgid "Disconnected from IRC ({1}). Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1302 +msgid "If you trust this certificate, do /znc AddTrustedServerFingerprint {1}" +msgstr "" + +#: IRCSock.cpp:1319 +msgid "IRC connection timed out. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1331 +msgid "Connection Refused. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1339 +msgid "Received a too long line from the IRC server!" +msgstr "" + +#: IRCSock.cpp:1443 +msgid "No free nick available" +msgstr "" + +#: IRCSock.cpp:1451 +msgid "No free nick found" +msgstr "" + +#: Client.cpp:75 +msgid "No such module {1}" +msgstr "" + +#: Client.cpp:365 +msgid "A client from {1} attempted to login as you, but was rejected: {2}" +msgstr "" + +#: Client.cpp:400 +msgid "Network {1} doesn't exist." +msgstr "" + +#: Client.cpp:414 +msgid "" +"You have several networks configured, but no network was specified for the " +"connection." +msgstr "" + +#: Client.cpp:417 +msgid "" +"Selecting network {1}. To see list of all configured networks, use /znc " +"ListNetworks" +msgstr "" + +#: Client.cpp:420 +msgid "" +"If you want to choose another network, use /znc JumpNetwork , or " +"connect to ZNC with username {1}/ (instead of just {1})" +msgstr "" + +#: Client.cpp:426 +msgid "" +"You have no networks configured. Use /znc AddNetwork to add one." +msgstr "" + +#: Client.cpp:437 +msgid "Closing link: Timeout" +msgstr "" + +#: Client.cpp:459 +msgid "Closing link: Too long raw line" +msgstr "" + +#: Client.cpp:466 +msgid "" +"You are being disconnected because another user just authenticated as you." +msgstr "" + +#: Client.cpp:1021 +msgid "Your CTCP to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1148 +msgid "Your notice to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1187 +msgid "Removing channel {1}" +msgstr "" + +#: Client.cpp:1264 +msgid "Your message to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1317 Client.cpp:1323 +msgid "Hello. How may I help you?" +msgstr "" + +#: Client.cpp:1337 +msgid "Usage: /attach <#chans>" +msgstr "" + +#: Client.cpp:1344 Client.cpp:1366 ClientCommand.cpp:129 ClientCommand.cpp:151 +msgid "There was {1} channel matching [{2}]" +msgid_plural "There were {1} channels matching [{2}]" +msgstr[0] "" +msgstr[1] "" + +#: Client.cpp:1347 ClientCommand.cpp:132 +msgid "Attached {1} channel" +msgid_plural "Attached {1} channels" +msgstr[0] "" +msgstr[1] "" + +#: Client.cpp:1359 +msgid "Usage: /detach <#chans>" +msgstr "" + +#: Client.cpp:1369 ClientCommand.cpp:154 +msgid "Detached {1} channel" +msgid_plural "Detached {1} channels" +msgstr[0] "" +msgstr[1] "" + #: Chan.cpp:638 msgid "Buffer Playback..." msgstr "" @@ -63,6 +283,120 @@ msgstr "" msgid "Playback Complete." msgstr "" +#: Modules.cpp:528 +msgctxt "modhelpcmd" +msgid "" +msgstr "" + +#: Modules.cpp:529 +msgctxt "modhelpcmd" +msgid "Generate this output" +msgstr "" + +#: Modules.cpp:573 ClientCommand.cpp:1894 +msgid "No matches for '{1}'" +msgstr "" + +#: Modules.cpp:691 +msgid "This module doesn't implement any commands." +msgstr "" + +#: Modules.cpp:693 +msgid "Unknown command!" +msgstr "" + +#: Modules.cpp:1633 +msgid "Module {1} already loaded." +msgstr "" + +#: Modules.cpp:1647 +msgid "Unable to find module {1}" +msgstr "" + +#: Modules.cpp:1659 +msgid "Module {1} does not support module type {1}." +msgstr "" + +#: Modules.cpp:1666 +msgid "Module {1} requires a user." +msgstr "" + +#: Modules.cpp:1672 +msgid "Module {1} requires a network." +msgstr "" + +#: Modules.cpp:1688 +msgid "Caught an exception" +msgstr "" + +#: Modules.cpp:1694 +msgid "Module {1} aborted: {2}" +msgstr "" + +#: Modules.cpp:1696 +msgid "Module {1} aborted." +msgstr "" + +#: Modules.cpp:1720 Modules.cpp:1762 +msgid "Module [{1}] not loaded." +msgstr "" + +#: Modules.cpp:1744 +msgid "Module {1} unloaded." +msgstr "" + +#: Modules.cpp:1749 +msgid "Unable to unload module {1}." +msgstr "" + +#: Modules.cpp:1778 +msgid "Reloaded module {1}." +msgstr "" + +#: Modules.cpp:1793 +msgid "Unable to find module {1}." +msgstr "" + +#: Modules.cpp:1919 +msgid "" +"Module names can only contain letters, numbers and underscores, [{1}] is " +"invalid" +msgstr "" + +#: Modules.cpp:1943 +msgid "Unknown error" +msgstr "" + +#: Modules.cpp:1944 +msgid "Unable to open module {1}: {2}" +msgstr "" + +#: Modules.cpp:1953 +msgid "Could not find ZNCModuleEntry in module {1}" +msgstr "" + +#: Modules.cpp:1961 +msgid "" +"Version mismatch for module {1}: core is {2}, module is built for {3}. " +"Recompile this module." +msgstr "" + +#: Modules.cpp:1972 +msgid "" +"Module {1} is built incompatibly: core is '{2}', module is '{3}'. Recompile " +"this module." +msgstr "" + +#: Modules.cpp:2002 Modules.cpp:2008 +msgctxt "modhelpcmd" +msgid "Command" +msgstr "" + +#: Modules.cpp:2003 Modules.cpp:2009 +msgctxt "modhelpcmd" +msgid "Description" +msgstr "" + #: ClientCommand.cpp:51 ClientCommand.cpp:115 ClientCommand.cpp:137 #: ClientCommand.cpp:749 ClientCommand.cpp:768 ClientCommand.cpp:794 #: ClientCommand.cpp:827 ClientCommand.cpp:840 ClientCommand.cpp:853 @@ -105,28 +439,10 @@ msgstr "" msgid "Usage: Attach <#chans>" msgstr "" -#: ClientCommand.cpp:129 ClientCommand.cpp:151 -msgid "There was {1} channel matching [{2}]" -msgid_plural "There were {1} channels matching [{2}]" -msgstr[0] "" -msgstr[1] "" - -#: ClientCommand.cpp:132 -msgid "Attached {1} channel" -msgid_plural "Attached {1} channels" -msgstr[0] "" -msgstr[1] "" - #: ClientCommand.cpp:144 msgid "Usage: Detach <#chans>" msgstr "" -#: ClientCommand.cpp:154 -msgid "Detached {1} channel" -msgid_plural "Detached {1} channels" -msgstr[0] "" -msgstr[1] "" - #: ClientCommand.cpp:161 msgid "There is no MOTD set." msgstr "" @@ -861,10 +1177,6 @@ msgid "" "Usage: AddPort <[+]port> [bindhost [uriprefix]]" msgstr "" -#: ClientCommand.cpp:1629 -msgid "Unable to bind: {1}" -msgstr "" - #: ClientCommand.cpp:1632 msgid "Port added" msgstr "" @@ -1358,6 +1670,68 @@ msgctxt "helpcmd|Restart|desc" msgid "Restart ZNC" msgstr "" -#: ClientCommand.cpp:1894 -msgid "No matches for '{1}'" +#: Socket.cpp:336 +msgid "Can't resolve server hostname" +msgstr "" + +#: Socket.cpp:343 +msgid "" +"Can't resolve bind hostname. Try /znc ClearBindHost and /znc " +"ClearUserBindHost" +msgstr "" + +#: Socket.cpp:348 +msgid "Server address is IPv4-only, but bindhost is IPv6-only" +msgstr "" + +#: Socket.cpp:357 +msgid "Server address is IPv6-only, but bindhost is IPv4-only" +msgstr "" + +#: Socket.cpp:515 +msgid "Some socket reached its max buffer limit and was closed!" +msgstr "" + +#: SSLVerifyHost.cpp:448 +msgid "hostname doesn't match" +msgstr "" + +#: SSLVerifyHost.cpp:452 +msgid "malformed hostname in certificate" +msgstr "" + +#: SSLVerifyHost.cpp:456 +msgid "hostname verification error" +msgstr "" + +#: User.cpp:507 +msgid "" +"Invalid network name. It should be alphanumeric. Not to be confused with " +"server name" +msgstr "" + +#: User.cpp:511 +msgid "Network {1} already exists" +msgstr "" + +#: User.cpp:777 +msgid "" +"You are being disconnected because your IP is no longer allowed to connect " +"to this user" +msgstr "" + +#: User.cpp:907 +msgid "Password is empty" +msgstr "" + +#: User.cpp:912 +msgid "Username is empty" +msgstr "" + +#: User.cpp:917 +msgid "Username is invalid" +msgstr "" + +#: User.cpp:1188 +msgid "Unable to find modinfo {1}: {2}" msgstr "" diff --git a/src/po/znc.pot b/src/po/znc.pot index 6b19d067..0badeab9 100644 --- a/src/po/znc.pot +++ b/src/po/znc.pot @@ -42,6 +42,226 @@ msgid "" "code>”). Once you have loaded some Web-enabled modules, the menu will expand." msgstr "" +#: znc.cpp:1563 +msgid "User already exists" +msgstr "" + +#: znc.cpp:1671 +msgid "IPv6 is not enabled" +msgstr "" + +#: znc.cpp:1679 +msgid "SSL is not enabled" +msgstr "" + +#: znc.cpp:1687 +msgid "Unable to locate pem file: {1}" +msgstr "" + +#: znc.cpp:1706 +msgid "Invalid port" +msgstr "" + +#: znc.cpp:1822 ClientCommand.cpp:1629 +msgid "Unable to bind: {1}" +msgstr "" + +#: IRCNetwork.cpp:236 +msgid "Jumping servers because this server is no longer in the list" +msgstr "" + +#: IRCNetwork.cpp:641 User.cpp:678 +msgid "Welcome to ZNC" +msgstr "" + +#: IRCNetwork.cpp:729 +msgid "You are currently disconnected from IRC. Use 'connect' to reconnect." +msgstr "" + +#: IRCNetwork.cpp:734 +msgid "" +"ZNC is presently running in DEBUG mode. Sensitive data during your current " +"session may be exposed to the host." +msgstr "" + +#: IRCNetwork.cpp:765 +msgid "This network is being deleted or moved to another user." +msgstr "" + +#: IRCNetwork.cpp:994 +msgid "The channel {1} could not be joined, disabling it." +msgstr "" + +#: IRCNetwork.cpp:1123 +msgid "Your current server was removed, jumping..." +msgstr "" + +#: IRCNetwork.cpp:1286 +msgid "Cannot connect to {1}, because ZNC is not compiled with SSL support." +msgstr "" + +#: IRCNetwork.cpp:1307 +msgid "Some module aborted the connection attempt" +msgstr "" + +#: IRCSock.cpp:484 +msgid "Error from server: {1}" +msgstr "" + +#: IRCSock.cpp:686 +msgid "ZNC seems to be connected to itself, disconnecting..." +msgstr "" + +#: IRCSock.cpp:733 +msgid "Server {1} redirects us to {2}:{3} with reason: {3}" +msgstr "" + +#: IRCSock.cpp:737 +msgid "Perhaps you want to add it as a new server." +msgstr "" + +#: IRCSock.cpp:967 +msgid "Channel {1} is linked to another channel and was thus disabled." +msgstr "" + +#: IRCSock.cpp:979 +msgid "Switched to SSL (STARTTLS)" +msgstr "" + +#: IRCSock.cpp:1032 +msgid "You quit: {1}" +msgstr "" + +#: IRCSock.cpp:1238 +msgid "Disconnected from IRC. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1269 +msgid "Cannot connect to IRC ({1}). Retrying..." +msgstr "" + +#: IRCSock.cpp:1272 +msgid "Disconnected from IRC ({1}). Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1302 +msgid "If you trust this certificate, do /znc AddTrustedServerFingerprint {1}" +msgstr "" + +#: IRCSock.cpp:1319 +msgid "IRC connection timed out. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1331 +msgid "Connection Refused. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1339 +msgid "Received a too long line from the IRC server!" +msgstr "" + +#: IRCSock.cpp:1443 +msgid "No free nick available" +msgstr "" + +#: IRCSock.cpp:1451 +msgid "No free nick found" +msgstr "" + +#: Client.cpp:75 +msgid "No such module {1}" +msgstr "" + +#: Client.cpp:365 +msgid "A client from {1} attempted to login as you, but was rejected: {2}" +msgstr "" + +#: Client.cpp:400 +msgid "Network {1} doesn't exist." +msgstr "" + +#: Client.cpp:414 +msgid "" +"You have several networks configured, but no network was specified for the " +"connection." +msgstr "" + +#: Client.cpp:417 +msgid "" +"Selecting network {1}. To see list of all configured networks, use /znc " +"ListNetworks" +msgstr "" + +#: Client.cpp:420 +msgid "" +"If you want to choose another network, use /znc JumpNetwork , or " +"connect to ZNC with username {1}/ (instead of just {1})" +msgstr "" + +#: Client.cpp:426 +msgid "" +"You have no networks configured. Use /znc AddNetwork to add one." +msgstr "" + +#: Client.cpp:437 +msgid "Closing link: Timeout" +msgstr "" + +#: Client.cpp:459 +msgid "Closing link: Too long raw line" +msgstr "" + +#: Client.cpp:466 +msgid "" +"You are being disconnected because another user just authenticated as you." +msgstr "" + +#: Client.cpp:1021 +msgid "Your CTCP to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1148 +msgid "Your notice to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1187 +msgid "Removing channel {1}" +msgstr "" + +#: Client.cpp:1264 +msgid "Your message to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1317 Client.cpp:1323 +msgid "Hello. How may I help you?" +msgstr "" + +#: Client.cpp:1337 +msgid "Usage: /attach <#chans>" +msgstr "" + +#: Client.cpp:1344 Client.cpp:1366 ClientCommand.cpp:129 ClientCommand.cpp:151 +msgid "There was {1} channel matching [{2}]" +msgid_plural "There were {1} channels matching [{2}]" +msgstr[0] "" +msgstr[1] "" + +#: Client.cpp:1347 ClientCommand.cpp:132 +msgid "Attached {1} channel" +msgid_plural "Attached {1} channels" +msgstr[0] "" +msgstr[1] "" + +#: Client.cpp:1359 +msgid "Usage: /detach <#chans>" +msgstr "" + +#: Client.cpp:1369 ClientCommand.cpp:154 +msgid "Detached {1} channel" +msgid_plural "Detached {1} channels" +msgstr[0] "" +msgstr[1] "" + #: Chan.cpp:638 msgid "Buffer Playback..." msgstr "" @@ -50,6 +270,120 @@ msgstr "" msgid "Playback Complete." msgstr "" +#: Modules.cpp:528 +msgctxt "modhelpcmd" +msgid "" +msgstr "" + +#: Modules.cpp:529 +msgctxt "modhelpcmd" +msgid "Generate this output" +msgstr "" + +#: Modules.cpp:573 ClientCommand.cpp:1894 +msgid "No matches for '{1}'" +msgstr "" + +#: Modules.cpp:691 +msgid "This module doesn't implement any commands." +msgstr "" + +#: Modules.cpp:693 +msgid "Unknown command!" +msgstr "" + +#: Modules.cpp:1633 +msgid "Module {1} already loaded." +msgstr "" + +#: Modules.cpp:1647 +msgid "Unable to find module {1}" +msgstr "" + +#: Modules.cpp:1659 +msgid "Module {1} does not support module type {1}." +msgstr "" + +#: Modules.cpp:1666 +msgid "Module {1} requires a user." +msgstr "" + +#: Modules.cpp:1672 +msgid "Module {1} requires a network." +msgstr "" + +#: Modules.cpp:1688 +msgid "Caught an exception" +msgstr "" + +#: Modules.cpp:1694 +msgid "Module {1} aborted: {2}" +msgstr "" + +#: Modules.cpp:1696 +msgid "Module {1} aborted." +msgstr "" + +#: Modules.cpp:1720 Modules.cpp:1762 +msgid "Module [{1}] not loaded." +msgstr "" + +#: Modules.cpp:1744 +msgid "Module {1} unloaded." +msgstr "" + +#: Modules.cpp:1749 +msgid "Unable to unload module {1}." +msgstr "" + +#: Modules.cpp:1778 +msgid "Reloaded module {1}." +msgstr "" + +#: Modules.cpp:1793 +msgid "Unable to find module {1}." +msgstr "" + +#: Modules.cpp:1919 +msgid "" +"Module names can only contain letters, numbers and underscores, [{1}] is " +"invalid" +msgstr "" + +#: Modules.cpp:1943 +msgid "Unknown error" +msgstr "" + +#: Modules.cpp:1944 +msgid "Unable to open module {1}: {2}" +msgstr "" + +#: Modules.cpp:1953 +msgid "Could not find ZNCModuleEntry in module {1}" +msgstr "" + +#: Modules.cpp:1961 +msgid "" +"Version mismatch for module {1}: core is {2}, module is built for {3}. " +"Recompile this module." +msgstr "" + +#: Modules.cpp:1972 +msgid "" +"Module {1} is built incompatibly: core is '{2}', module is '{3}'. Recompile " +"this module." +msgstr "" + +#: Modules.cpp:2002 Modules.cpp:2008 +msgctxt "modhelpcmd" +msgid "Command" +msgstr "" + +#: Modules.cpp:2003 Modules.cpp:2009 +msgctxt "modhelpcmd" +msgid "Description" +msgstr "" + #: ClientCommand.cpp:51 ClientCommand.cpp:115 ClientCommand.cpp:137 #: ClientCommand.cpp:749 ClientCommand.cpp:768 ClientCommand.cpp:794 #: ClientCommand.cpp:827 ClientCommand.cpp:840 ClientCommand.cpp:853 @@ -91,28 +425,10 @@ msgstr "" msgid "Usage: Attach <#chans>" msgstr "" -#: ClientCommand.cpp:129 ClientCommand.cpp:151 -msgid "There was {1} channel matching [{2}]" -msgid_plural "There were {1} channels matching [{2}]" -msgstr[0] "" -msgstr[1] "" - -#: ClientCommand.cpp:132 -msgid "Attached {1} channel" -msgid_plural "Attached {1} channels" -msgstr[0] "" -msgstr[1] "" - #: ClientCommand.cpp:144 msgid "Usage: Detach <#chans>" msgstr "" -#: ClientCommand.cpp:154 -msgid "Detached {1} channel" -msgid_plural "Detached {1} channels" -msgstr[0] "" -msgstr[1] "" - #: ClientCommand.cpp:161 msgid "There is no MOTD set." msgstr "" @@ -847,10 +1163,6 @@ msgid "" "Usage: AddPort <[+]port> [bindhost [uriprefix]]" msgstr "" -#: ClientCommand.cpp:1629 -msgid "Unable to bind: {1}" -msgstr "" - #: ClientCommand.cpp:1632 msgid "Port added" msgstr "" @@ -1344,6 +1656,68 @@ msgctxt "helpcmd|Restart|desc" msgid "Restart ZNC" msgstr "" -#: ClientCommand.cpp:1894 -msgid "No matches for '{1}'" +#: Socket.cpp:336 +msgid "Can't resolve server hostname" +msgstr "" + +#: Socket.cpp:343 +msgid "" +"Can't resolve bind hostname. Try /znc ClearBindHost and /znc " +"ClearUserBindHost" +msgstr "" + +#: Socket.cpp:348 +msgid "Server address is IPv4-only, but bindhost is IPv6-only" +msgstr "" + +#: Socket.cpp:357 +msgid "Server address is IPv6-only, but bindhost is IPv4-only" +msgstr "" + +#: Socket.cpp:515 +msgid "Some socket reached its max buffer limit and was closed!" +msgstr "" + +#: SSLVerifyHost.cpp:448 +msgid "hostname doesn't match" +msgstr "" + +#: SSLVerifyHost.cpp:452 +msgid "malformed hostname in certificate" +msgstr "" + +#: SSLVerifyHost.cpp:456 +msgid "hostname verification error" +msgstr "" + +#: User.cpp:507 +msgid "" +"Invalid network name. It should be alphanumeric. Not to be confused with " +"server name" +msgstr "" + +#: User.cpp:511 +msgid "Network {1} already exists" +msgstr "" + +#: User.cpp:777 +msgid "" +"You are being disconnected because your IP is no longer allowed to connect " +"to this user" +msgstr "" + +#: User.cpp:907 +msgid "Password is empty" +msgstr "" + +#: User.cpp:912 +msgid "Username is empty" +msgstr "" + +#: User.cpp:917 +msgid "Username is invalid" +msgstr "" + +#: User.cpp:1188 +msgid "Unable to find modinfo {1}: {2}" msgstr "" diff --git a/src/po/znc.ru.po b/src/po/znc.ru.po index 30f03514..bc60f4a7 100644 --- a/src/po/znc.ru.po +++ b/src/po/znc.ru.po @@ -57,6 +57,232 @@ msgstr "" "модуль>»). Когда такие модули будут загружены, они будут доступны " "в меню сбоку." +#: znc.cpp:1563 +msgid "User already exists" +msgstr "" + +#: znc.cpp:1671 +msgid "IPv6 is not enabled" +msgstr "" + +#: znc.cpp:1679 +msgid "SSL is not enabled" +msgstr "" + +#: znc.cpp:1687 +msgid "Unable to locate pem file: {1}" +msgstr "" + +#: znc.cpp:1706 +msgid "Invalid port" +msgstr "" + +#: znc.cpp:1822 ClientCommand.cpp:1629 +msgid "Unable to bind: {1}" +msgstr "" + +#: IRCNetwork.cpp:236 +msgid "Jumping servers because this server is no longer in the list" +msgstr "" + +#: IRCNetwork.cpp:641 User.cpp:678 +msgid "Welcome to ZNC" +msgstr "" + +#: IRCNetwork.cpp:729 +msgid "You are currently disconnected from IRC. Use 'connect' to reconnect." +msgstr "" + +#: IRCNetwork.cpp:734 +msgid "" +"ZNC is presently running in DEBUG mode. Sensitive data during your current " +"session may be exposed to the host." +msgstr "" + +#: IRCNetwork.cpp:765 +msgid "This network is being deleted or moved to another user." +msgstr "" + +#: IRCNetwork.cpp:994 +msgid "The channel {1} could not be joined, disabling it." +msgstr "" + +#: IRCNetwork.cpp:1123 +msgid "Your current server was removed, jumping..." +msgstr "" + +#: IRCNetwork.cpp:1286 +msgid "Cannot connect to {1}, because ZNC is not compiled with SSL support." +msgstr "" + +#: IRCNetwork.cpp:1307 +msgid "Some module aborted the connection attempt" +msgstr "" + +#: IRCSock.cpp:484 +msgid "Error from server: {1}" +msgstr "" + +#: IRCSock.cpp:686 +msgid "ZNC seems to be connected to itself, disconnecting..." +msgstr "" + +#: IRCSock.cpp:733 +msgid "Server {1} redirects us to {2}:{3} with reason: {3}" +msgstr "" + +#: IRCSock.cpp:737 +msgid "Perhaps you want to add it as a new server." +msgstr "" + +#: IRCSock.cpp:967 +msgid "Channel {1} is linked to another channel and was thus disabled." +msgstr "" + +#: IRCSock.cpp:979 +msgid "Switched to SSL (STARTTLS)" +msgstr "" + +#: IRCSock.cpp:1032 +msgid "You quit: {1}" +msgstr "" + +#: IRCSock.cpp:1238 +msgid "Disconnected from IRC. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1269 +msgid "Cannot connect to IRC ({1}). Retrying..." +msgstr "" + +#: IRCSock.cpp:1272 +msgid "Disconnected from IRC ({1}). Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1302 +msgid "If you trust this certificate, do /znc AddTrustedServerFingerprint {1}" +msgstr "" + +#: IRCSock.cpp:1319 +msgid "IRC connection timed out. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1331 +msgid "Connection Refused. Reconnecting..." +msgstr "" + +#: IRCSock.cpp:1339 +msgid "Received a too long line from the IRC server!" +msgstr "" + +#: IRCSock.cpp:1443 +msgid "No free nick available" +msgstr "" + +#: IRCSock.cpp:1451 +msgid "No free nick found" +msgstr "" + +#: Client.cpp:75 +msgid "No such module {1}" +msgstr "" + +#: Client.cpp:365 +msgid "A client from {1} attempted to login as you, but was rejected: {2}" +msgstr "" + +#: Client.cpp:400 +msgid "Network {1} doesn't exist." +msgstr "" + +#: Client.cpp:414 +msgid "" +"You have several networks configured, but no network was specified for the " +"connection." +msgstr "" + +#: Client.cpp:417 +msgid "" +"Selecting network {1}. To see list of all configured networks, use /znc " +"ListNetworks" +msgstr "" + +#: Client.cpp:420 +msgid "" +"If you want to choose another network, use /znc JumpNetwork , or " +"connect to ZNC with username {1}/ (instead of just {1})" +msgstr "" + +#: Client.cpp:426 +msgid "" +"You have no networks configured. Use /znc AddNetwork to add one." +msgstr "" + +#: Client.cpp:437 +msgid "Closing link: Timeout" +msgstr "" + +#: Client.cpp:459 +msgid "Closing link: Too long raw line" +msgstr "" + +#: Client.cpp:466 +msgid "" +"You are being disconnected because another user just authenticated as you." +msgstr "" + +#: Client.cpp:1021 +msgid "Your CTCP to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1148 +msgid "Your notice to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1187 +msgid "Removing channel {1}" +msgstr "" + +#: Client.cpp:1264 +msgid "Your message to {1} got lost, you are not connected to IRC!" +msgstr "" + +#: Client.cpp:1317 Client.cpp:1323 +msgid "Hello. How may I help you?" +msgstr "" + +#: Client.cpp:1337 +msgid "Usage: /attach <#chans>" +msgstr "" + +#: Client.cpp:1344 Client.cpp:1366 ClientCommand.cpp:129 ClientCommand.cpp:151 +msgid "There was {1} channel matching [{2}]" +msgid_plural "There were {1} channels matching [{2}]" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: Client.cpp:1347 ClientCommand.cpp:132 +msgid "Attached {1} channel" +msgid_plural "Attached {1} channels" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + +#: Client.cpp:1359 +msgid "Usage: /detach <#chans>" +msgstr "" + +#: Client.cpp:1369 ClientCommand.cpp:154 +msgid "Detached {1} channel" +msgid_plural "Detached {1} channels" +msgstr[0] "" +msgstr[1] "" +msgstr[2] "" +msgstr[3] "" + #: Chan.cpp:638 msgid "Buffer Playback..." msgstr "" @@ -65,6 +291,120 @@ msgstr "" msgid "Playback Complete." msgstr "" +#: Modules.cpp:528 +msgctxt "modhelpcmd" +msgid "" +msgstr "" + +#: Modules.cpp:529 +msgctxt "modhelpcmd" +msgid "Generate this output" +msgstr "" + +#: Modules.cpp:573 ClientCommand.cpp:1894 +msgid "No matches for '{1}'" +msgstr "" + +#: Modules.cpp:691 +msgid "This module doesn't implement any commands." +msgstr "" + +#: Modules.cpp:693 +msgid "Unknown command!" +msgstr "" + +#: Modules.cpp:1633 +msgid "Module {1} already loaded." +msgstr "" + +#: Modules.cpp:1647 +msgid "Unable to find module {1}" +msgstr "" + +#: Modules.cpp:1659 +msgid "Module {1} does not support module type {1}." +msgstr "" + +#: Modules.cpp:1666 +msgid "Module {1} requires a user." +msgstr "" + +#: Modules.cpp:1672 +msgid "Module {1} requires a network." +msgstr "" + +#: Modules.cpp:1688 +msgid "Caught an exception" +msgstr "" + +#: Modules.cpp:1694 +msgid "Module {1} aborted: {2}" +msgstr "" + +#: Modules.cpp:1696 +msgid "Module {1} aborted." +msgstr "" + +#: Modules.cpp:1720 Modules.cpp:1762 +msgid "Module [{1}] not loaded." +msgstr "" + +#: Modules.cpp:1744 +msgid "Module {1} unloaded." +msgstr "" + +#: Modules.cpp:1749 +msgid "Unable to unload module {1}." +msgstr "" + +#: Modules.cpp:1778 +msgid "Reloaded module {1}." +msgstr "" + +#: Modules.cpp:1793 +msgid "Unable to find module {1}." +msgstr "" + +#: Modules.cpp:1919 +msgid "" +"Module names can only contain letters, numbers and underscores, [{1}] is " +"invalid" +msgstr "" + +#: Modules.cpp:1943 +msgid "Unknown error" +msgstr "" + +#: Modules.cpp:1944 +msgid "Unable to open module {1}: {2}" +msgstr "" + +#: Modules.cpp:1953 +msgid "Could not find ZNCModuleEntry in module {1}" +msgstr "" + +#: Modules.cpp:1961 +msgid "" +"Version mismatch for module {1}: core is {2}, module is built for {3}. " +"Recompile this module." +msgstr "" + +#: Modules.cpp:1972 +msgid "" +"Module {1} is built incompatibly: core is '{2}', module is '{3}'. Recompile " +"this module." +msgstr "" + +#: Modules.cpp:2002 Modules.cpp:2008 +msgctxt "modhelpcmd" +msgid "Command" +msgstr "" + +#: Modules.cpp:2003 Modules.cpp:2009 +msgctxt "modhelpcmd" +msgid "Description" +msgstr "" + #: ClientCommand.cpp:51 ClientCommand.cpp:115 ClientCommand.cpp:137 #: ClientCommand.cpp:749 ClientCommand.cpp:768 ClientCommand.cpp:794 #: ClientCommand.cpp:827 ClientCommand.cpp:840 ClientCommand.cpp:853 @@ -76,11 +416,11 @@ msgstr "" #: ClientCommand.cpp:58 msgid "Usage: ListNicks <#chan>" -msgstr "" +msgstr "Использование: ListNicks <#chan>" #: ClientCommand.cpp:65 msgid "You are not on [{1}]" -msgstr "" +msgstr "Вы находитесь не на [{1}]" #: ClientCommand.cpp:70 msgid "You are not on [{1}] (trying)" @@ -92,47 +432,23 @@ msgstr "" #: ClientCommand.cpp:91 ClientCommand.cpp:106 msgid "Nick" -msgstr "" +msgstr "Ник" #: ClientCommand.cpp:92 ClientCommand.cpp:107 msgid "Ident" -msgstr "" +msgstr "Идент" #: ClientCommand.cpp:93 ClientCommand.cpp:108 msgid "Host" -msgstr "" +msgstr "Хост" #: ClientCommand.cpp:122 msgid "Usage: Attach <#chans>" -msgstr "" - -#: ClientCommand.cpp:129 ClientCommand.cpp:151 -msgid "There was {1} channel matching [{2}]" -msgid_plural "There were {1} channels matching [{2}]" -msgstr[0] "" -msgstr[1] "" -msgstr[2] "" -msgstr[3] "" - -#: ClientCommand.cpp:132 -msgid "Attached {1} channel" -msgid_plural "Attached {1} channels" -msgstr[0] "" -msgstr[1] "" -msgstr[2] "" -msgstr[3] "" +msgstr "Использование: Attach <#chans>" #: ClientCommand.cpp:144 msgid "Usage: Detach <#chans>" -msgstr "" - -#: ClientCommand.cpp:154 -msgid "Detached {1} channel" -msgid_plural "Detached {1} channels" -msgstr[0] "" -msgstr[1] "" -msgstr[2] "" -msgstr[3] "" +msgstr "Использование: Dettach <#chans>" #: ClientCommand.cpp:161 msgid "There is no MOTD set." @@ -193,7 +509,7 @@ msgstr "" #: ClientCommand.cpp:488 ClientCommand.cpp:516 msgctxt "listchans" msgid "Clear" -msgstr "" +msgstr "Очистить" #: ClientCommand.cpp:489 ClientCommand.cpp:521 msgctxt "listchans" @@ -203,7 +519,7 @@ msgstr "" #: ClientCommand.cpp:490 ClientCommand.cpp:522 msgctxt "listchans" msgid "Users" -msgstr "" +msgstr "Пользователи" #: ClientCommand.cpp:505 msgctxt "listchans" @@ -228,7 +544,7 @@ msgstr "" #: ClientCommand.cpp:511 ClientCommand.cpp:519 msgctxt "listchans" msgid "yes" -msgstr "" +msgstr "да" #: ClientCommand.cpp:536 msgid "Total: {1}, Joined: {2}, Detached: {3}, Disabled: {4}" @@ -242,7 +558,7 @@ msgstr "" #: ClientCommand.cpp:550 msgid "Usage: AddNetwork " -msgstr "" +msgstr "Использование: AddNetwork " #: ClientCommand.cpp:554 msgid "Network name should be alphanumeric" @@ -264,7 +580,7 @@ msgstr "" #: ClientCommand.cpp:582 msgid "Network deleted" -msgstr "" +msgstr "Сеть удалена" #: ClientCommand.cpp:585 msgid "Failed to delete network, perhaps this network doesn't exist" @@ -272,12 +588,12 @@ msgstr "" #: ClientCommand.cpp:595 msgid "User {1} not found" -msgstr "" +msgstr "Пользователь {1} не найден" #: ClientCommand.cpp:603 ClientCommand.cpp:611 msgctxt "listnetworks" msgid "Network" -msgstr "" +msgstr "Сеть" #: ClientCommand.cpp:604 ClientCommand.cpp:613 ClientCommand.cpp:622 msgctxt "listnetworks" @@ -794,107 +1110,105 @@ msgstr "" #: ClientCommand.cpp:1530 msgid "Unknown command, try 'Help'" -msgstr "" +msgstr "Неизвестная команда, попробуйте 'Help'" #: ClientCommand.cpp:1539 ClientCommand.cpp:1550 msgctxt "listports" msgid "Port" -msgstr "" +msgstr "Порт" #: ClientCommand.cpp:1540 ClientCommand.cpp:1551 msgctxt "listports" msgid "BindHost" -msgstr "" +msgstr "BindHost" #: ClientCommand.cpp:1541 ClientCommand.cpp:1554 msgctxt "listports" msgid "SSL" -msgstr "" +msgstr "SSL" #: ClientCommand.cpp:1542 ClientCommand.cpp:1559 msgctxt "listports" msgid "Protocol" -msgstr "" +msgstr "Протокол" #: ClientCommand.cpp:1543 ClientCommand.cpp:1566 msgctxt "listports" msgid "IRC" -msgstr "" +msgstr "IRC" #: ClientCommand.cpp:1544 ClientCommand.cpp:1571 msgctxt "listports" msgid "Web" -msgstr "" +msgstr "Веб" #: ClientCommand.cpp:1555 msgctxt "listports|ssl" msgid "yes" -msgstr "" +msgstr "да" #: ClientCommand.cpp:1556 msgctxt "listports|ssl" msgid "no" -msgstr "" +msgstr "нет" #: ClientCommand.cpp:1560 msgctxt "listports" msgid "IPv4 and IPv6" -msgstr "" +msgstr "IPv4 и IPv6" #: ClientCommand.cpp:1562 msgctxt "listports" msgid "IPv4" -msgstr "" +msgstr "IPv4" #: ClientCommand.cpp:1563 msgctxt "listports" msgid "IPv6" -msgstr "" +msgstr "IPv6" #: ClientCommand.cpp:1569 msgctxt "listports|irc" msgid "yes" -msgstr "" +msgstr "да" #: ClientCommand.cpp:1570 msgctxt "listports|irc" msgid "no" -msgstr "" +msgstr "нет" #: ClientCommand.cpp:1574 msgctxt "listports|irc" msgid "yes, on {1}" -msgstr "" +msgstr "да, на {1}" #: ClientCommand.cpp:1576 msgctxt "listports|web" msgid "no" -msgstr "" +msgstr "нет" #: ClientCommand.cpp:1616 msgid "" "Usage: AddPort <[+]port> [bindhost [uriprefix]]" msgstr "" - -#: ClientCommand.cpp:1629 -msgid "Unable to bind: {1}" -msgstr "" +"Использование: AddPort <[+]port> [bindhost " +"[uriprefix]]" #: ClientCommand.cpp:1632 msgid "Port added" -msgstr "" +msgstr "Порт добавлен" #: ClientCommand.cpp:1634 msgid "Couldn't add port" -msgstr "" +msgstr "Невозможно добавить порт" #: ClientCommand.cpp:1640 msgid "Usage: DelPort [bindhost]" -msgstr "" +msgstr "Использование: DelPort [bindhost]" #: ClientCommand.cpp:1649 msgid "Deleted Port" -msgstr "" +msgstr "Удален порт" #: ClientCommand.cpp:1651 msgid "Unable to find a matching port" @@ -903,12 +1217,12 @@ msgstr "" #: ClientCommand.cpp:1659 ClientCommand.cpp:1673 msgctxt "helpcmd" msgid "Command" -msgstr "" +msgstr "Команда" #: ClientCommand.cpp:1660 ClientCommand.cpp:1674 msgctxt "helpcmd" msgid "Description" -msgstr "" +msgstr "Описание" #: ClientCommand.cpp:1664 msgid "" @@ -1373,6 +1687,68 @@ msgctxt "helpcmd|Restart|desc" msgid "Restart ZNC" msgstr "" -#: ClientCommand.cpp:1894 -msgid "No matches for '{1}'" +#: Socket.cpp:336 +msgid "Can't resolve server hostname" +msgstr "" + +#: Socket.cpp:343 +msgid "" +"Can't resolve bind hostname. Try /znc ClearBindHost and /znc " +"ClearUserBindHost" +msgstr "" + +#: Socket.cpp:348 +msgid "Server address is IPv4-only, but bindhost is IPv6-only" +msgstr "" + +#: Socket.cpp:357 +msgid "Server address is IPv6-only, but bindhost is IPv4-only" +msgstr "" + +#: Socket.cpp:515 +msgid "Some socket reached its max buffer limit and was closed!" +msgstr "" + +#: SSLVerifyHost.cpp:448 +msgid "hostname doesn't match" +msgstr "" + +#: SSLVerifyHost.cpp:452 +msgid "malformed hostname in certificate" +msgstr "" + +#: SSLVerifyHost.cpp:456 +msgid "hostname verification error" +msgstr "" + +#: User.cpp:507 +msgid "" +"Invalid network name. It should be alphanumeric. Not to be confused with " +"server name" +msgstr "" + +#: User.cpp:511 +msgid "Network {1} already exists" +msgstr "" + +#: User.cpp:777 +msgid "" +"You are being disconnected because your IP is no longer allowed to connect " +"to this user" +msgstr "" + +#: User.cpp:907 +msgid "Password is empty" +msgstr "" + +#: User.cpp:912 +msgid "Username is empty" +msgstr "" + +#: User.cpp:917 +msgid "Username is invalid" +msgstr "" + +#: User.cpp:1188 +msgid "Unable to find modinfo {1}: {2}" msgstr "" From d6bfe504ae2046b8cade8f08cc435bbeaf01f050 Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Wed, 4 Apr 2018 08:13:28 +0100 Subject: [PATCH 20/20] When Boost is not found via CMake, tell what exact features are disabled --- CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4dc7b063..d69d1f1e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -192,6 +192,7 @@ if(Boost_LOCALE_FOUND AND GETTEXT_MSGFMT_EXECUTABLE) set(HAVE_I18N true) else() set(HAVE_I18N false) + message(STATUS "Boost.Locale is not found, disabling i18n support") endif() if(HAVE_I18N AND GETTEXT_MSGMERGE_EXECUTABLE)