]> git.netwichtig.de Git - user/henk/code/inspircd.git/blob - src/coremods/core_info/cmd_info.cpp
Update copyright headers.
[user/henk/code/inspircd.git] / src / coremods / core_info / cmd_info.cpp
1 /*
2  * InspIRCd -- Internet Relay Chat Daemon
3  *
4  *   Copyright (C) 2017-2019 Sadie Powell <sadie@witchery.services>
5  *   Copyright (C) 2015 Robin Burchell <robin+git@viroteck.net>
6  *   Copyright (C) 2013-2014, 2016 Attila Molnar <attilamolnar@hush.com>
7  *   Copyright (C) 2012, 2019 Robby <robby@chatbelgie.be>
8  *   Copyright (C) 2009-2010 Daniel De Graaf <danieldg@inspircd.org>
9  *   Copyright (C) 2007, 2010 Craig Edwards <brain@inspircd.org>
10  *   Copyright (C) 2007 Dennis Friis <peavey@inspircd.org>
11  *
12  * This file is part of InspIRCd.  InspIRCd is free software: you can
13  * redistribute it and/or modify it under the terms of the GNU General Public
14  * License as published by the Free Software Foundation, version 2.
15  *
16  * This program is distributed in the hope that it will be useful, but WITHOUT
17  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
18  * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
19  * details.
20  *
21  * You should have received a copy of the GNU General Public License
22  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
23  */
24
25
26 #include "inspircd.h"
27 #include "core_info.h"
28
29 CommandInfo::CommandInfo(Module* parent)
30         : ServerTargetCommand(parent, "INFO")
31 {
32         Penalty = 4;
33         syntax = "[<servername>]";
34 }
35
36 static const char* const lines[] = {
37         "                   -/\\- \002InspIRCd\002 -\\/-",
38         "                 November 2002 - Present",
39         " ",
40         "\002Core Developers\002:",
41         "    Attila Molnar,          Attila,     <attilamolnar@hush.com>",
42         "    Sadie Powell,           SadieCat,   <sadie@witchery.services>",
43         " ",
44         "\002Former Developers\002:",
45         "    Oliver Lupton,          Om,         <om@inspircd.org>",
46         "    John Brooks,            Special,    <special@inspircd.org>",
47         "    Dennis Friis,           peavey,     <peavey@inspircd.org>",
48         "    Thomas Stagner,         aquanight,  <aquanight@inspircd.org>",
49         "    Uli Schlachter,         psychon,    <psychon@inspircd.org>",
50         "    Matt Smith,             dz,         <dz@inspircd.org>",
51         "    Daniel De Graaf,        danieldg,   <danieldg@inspircd.org>",
52         " ",
53         "\002Founding Developers\002:",
54         "    Craig Edwards,          Brain,      <brain@inspircd.org>",
55         "    Craig McLure,           Craig,      <craig@inspircd.org>",
56         "    Robin Burchell,         w00t,       <w00t@inspircd.org>",
57         " ",
58         "\002Active Contributors\002:",
59         "    Adam           linuxdaemon     Sheogorath",
60         " ",
61         "\002Former Contributors\002:",
62         "   dmb             Zaba            skenmy         GreenReaper",
63         "   Dan             Jason           satmd          owine",
64         "   Adremelech      John2           jilles         HiroP",
65         "   eggy            Bricker         AnMaster       djGrrr",
66         "   nenolod         Quension        praetorian     pippijn",
67         "   CC              jamie           typobox43      Burlex",
68         "   Stskeeps        ThaPrince       BuildSmart     Thunderhacker",
69         "   Skip            LeaChim         Majic          MacGyver",
70         "   Namegduf        Ankit           Phoenix        Taros",
71         "   jackmcbarn      ChrisTX         Shawn          Shutter",
72         " ",
73         "\002Thanks To\002:",
74         "   Asmo            Brik            fraggeln       genius3000",
75         " ",
76         " Best experienced with: \002An IRC client\002",
77         NULL
78 };
79
80 /** Handle /INFO
81  */
82 CmdResult CommandInfo::Handle(User* user, const Params& parameters)
83 {
84         if (parameters.size() > 0 && !irc::equals(parameters[0], ServerInstance->Config->ServerName))
85                 return CMD_SUCCESS;
86
87         int i=0;
88         while (lines[i])
89                 user->WriteRemoteNumeric(RPL_INFO, lines[i++]);
90
91         user->WriteRemoteNumeric(RPL_ENDOFINFO, "End of /INFO list");
92         return CMD_SUCCESS;
93 }