 
            Is there an way to set the default mode for new clients and/or channels? Thanks, Jerome
 
            -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 02/24/11 17:03, Jerome Rose wrote:
Is there an way to set the default mode for new clients and/or channels?
See the [Channels] section of the configuration, specifically the "Modes =" directive. For example: [Channel] # Pre-defined channels can be configured in [Channel] sections. # Such channels are created by the server when starting up and even # persist when there are no more members left. # Persistent channels are marked with the mode 'P', which can be set # and unset by IRC operators like other modes on the fly. # There may be more than one [Channel] block, one for each channel. # Name of the channel Name = #ngric # Topic for this channel Topic = Welcome # Initial channel modes Modes = tnk
Thanks, Jerome
- -- It has been said that "hate" is a powerful emotion, perhaps that's why I'm so strong. - -evilghost -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQIcBAEBAgAGBQJNZuzwAAoJENgimYXu6xOHQCUP/RaqXdZ6mofGonQCKq7frHcn nZ+I/m0U0Lpy+3v5DKnTCnK1PaPesQMZt8DWC1owdct9VLNo1JZif17Ws/8hZWuG KerSHezjMnQbzIFtv+h72UxS5VAHloA9xnitcsagaIQwk0y8i7EN2uu7TYYqrYcn mKtRk9nh9niEp4eAc2BBOqNOhxDTkT8t+4vaPeTBKOXihJk11UkDCC6FvKqJYEj2 1kG10hL2SEjY36880PScUk6N7UxxZUnDwoiSvTmSwmEQDvwXxBIQMHC5d52xxSZf 0FOsgSqxzCRhWvMn6sRnggH4SOZQaI1DPp9tNDGUIEG90rpcxqoiA6rsSYSBegOh iIZyWpUDMndNSh4tRFD8gowmsaoED2QLMVdjIhpz8vSgJG4MYAWrPnziy1aaq/gc vHc6A9bFmPEZQ5NGbwR7a4AYznJWHcozmpqa0Hl4OnP1ncGZryqXll92X+geNK1M 8od5AaskXLHoSvK+beKWQY9eZS3Zu3rfEWI6GewCtNs8TsPt2pbu1FAq8ShRFFw/ 8AyJaelgYkJOpoZsAVHjysOxl+qB3ABx9SSTvI+uh74sP7m5y/EH+KBY5R/dll+9 ZyIPpx0FltdbugMQ8xA+rTPFyBDky0d1vcqE5DptZsN43fsPwdy7e1ePqxbJZDSj uzMp6Id9pSqsyM0Cb+/u =bbAd -----END PGP SIGNATURE-----
 
            Also sprach Jerome Rose, at 2/24/11 4:03 PM:
Is there an way to set the default mode for new clients and/or channels?
In client.c, there's Init_New_Client(), which apparently takes a mode string. You could add a define in defines.h for default umodes and include that, so if( Modes ) Client_SetModes(client, Modes); would skip the if() since there are always modes to apply. There is probably a more elegant way to do this.
 
            For now I added a CLIENT_DEFAULT_MODE to defines and added it to the Init_New_Client call in the local client init function (line 146 in client.c). Works just fine for my current purposes, if I get some free time I'll look into doing the same for channels, and adding config parsing so they can be set at run time. If I do I'll send in a patch. Thanks for the quick replies. -Jerome On Thu, Feb 24, 2011 at 6:53 PM, Lucien Pullen <drurowin@gmail.com> wrote:
Also sprach Jerome Rose, at 2/24/11 4:03 PM:
Is there an way to set the default mode for new clients and/or channels?
In client.c, there's Init_New_Client(), which apparently takes a mode string.
You could add a define in defines.h for default umodes and include that, so
if( Modes ) Client_SetModes(client, Modes);
would skip the if() since there are always modes to apply. There is probably a more elegant way to do this. _______________________________________________
ngIRCd Mailing List: ngIRCd-ML@arthur.barton.de http://arthur.barton.de/mailman/listinfo/ngircd-ml
 
            Hi Jerome! Am Fr, 25.02.2011, 03:11 schrieb Jerome Rose:
For now I added a CLIENT_DEFAULT_MODE to defines and added it to the Init_New_Client call in the local client init function (line 146 in client.c). Works just fine for my current purposes,
Good to hear!
if I get some free time I'll look into doing the same for channels, and adding config parsing so they can be set at run time. If I do I'll send in a patch.
Patches are welcome as always :-) Please let us/me know if you need help. Regards Alex
Teilnehmer (4)
- 
                 Alexander Barton Alexander Barton
- 
                 evilghost@packetmail.net evilghost@packetmail.net
- 
                 Jerome Rose Jerome Rose
- 
                 Lucien Pullen Lucien Pullen