[cvslog] [CVS] Module eggdrop1.8: Change committed

cvs at eggheads.org cvs at eggheads.org
Tue Jul 30 18:20:16 CST 2013


CVSROOT    : /usr/local/cvsroot
Module     : eggdrop1.8
Commit time: 2013-07-31 00:20:15 UTC
Committer  : Thomas Sader <thommey at gmail.com>

Modified files:
     doc/Changes1.8 doc/tcl-commands.doc doc/html/tcl-commands.html
     help/cmds2.help src/cmds.c src/dcc.c src/tclmisc.c

Log message:

apply two patches by robby

---------------------- diff included ----------------------
Index: eggdrop1.8/doc/Changes1.8
diff -u eggdrop1.8/doc/Changes1.8:1.69 eggdrop1.8/doc/Changes1.8:1.70
--- eggdrop1.8/doc/Changes1.8:1.69	Mon Jul 29 09:49:40 2013
+++ eggdrop1.8/doc/Changes1.8	Tue Jul 30 18:20:05 2013
@@ -1,4 +1,4 @@
-$Id: Changes1.8,v 1.69 2013/07/29 15:49:40 thommey Exp $
+$Id: Changes1.8,v 1.70 2013/07/31 00:20:05 thommey Exp $
 
 Eggdrop Changes (since version 1.8.0)
 
@@ -6,6 +6,16 @@
 
 1.8.0 (CVS):
 
+  - Correct and add missing flags for .help strip, [strip] and [stripcodes]
+    Patch by: Robby
+
+  - Fixed a typo in the html documentation.
+    Found by: Johannes13 / Patch by: pseudo
+
+  - Fixed the .match command help.
+    Fixes Trac Bug #85 "dcc match command documentation"
+    Found by: jack3 / Patch by: pseudo
+
   - Against all odds we survived unixtime 999999999.
     Patch by: thommey / Found by: Robby
 
Index: eggdrop1.8/doc/html/tcl-commands.html
diff -u eggdrop1.8/doc/html/tcl-commands.html:1.13 eggdrop1.8/doc/html/tcl-commands.html:1.14
--- eggdrop1.8/doc/html/tcl-commands.html:1.13	Tue Jun 26 15:20:49 2012
+++ eggdrop1.8/doc/html/tcl-commands.html	Tue Jul 30 18:20:05 2013
@@ -1,5 +1,5 @@
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<!-- $Id: tcl-commands.html,v 1.13 2012/06/26 21:20:49 thommey Exp $ -->
+<!-- $Id: tcl-commands.html,v 1.14 2013/07/31 00:20:05 thommey Exp $ -->
 
 <html>
   <head>
@@ -506,7 +506,7 @@
           <p><strong>Description:</strong> changes the attributes for a user
           record, if you include any. Changes are of the form '+f',
           '-o', '+dk', '-o+d', etc. If changes are
-          specified in the format of <changes> <channel<, the
+          specified in the format of <changes> <channel>, the
           channel-specific flags for that channel are altered. You can now
           use the +o|-o #channel format here too.</p>
 
@@ -2036,21 +2036,21 @@
             <table>
               <tr valign="top">
                 <td>
-                  <p><strong>b</strong></p>
+                  <p><strong>c</strong></p>
                 </td>
 
                 <td>
-                  <p>remove all boldface codes</p>
+                  <p>remove all color codes</p>
                 </td>
               </tr>
 
               <tr valign="top">
                 <td>
-                  <p><strong>c</strong></p>
+                  <p><strong>b</strong></p>
                 </td>
 
                 <td>
-                  <p>remove all color codes</p>
+                  <p>remove all boldface codes</p>
                 </td>
               </tr>
 
@@ -2074,7 +2074,6 @@
                 </td>
               </tr>
 
-
               <tr valign="top">
                 <td>
                   <p><strong>a</strong></p>
@@ -2094,6 +2093,35 @@
                   <p>remove all ctrl-g (bell) codes</p>
                 </td>
               </tr>
+
+              <tr valign="top">
+                <td>
+                  <p><strong>o</strong></p>
+                </td>
+
+                <td>
+                  <p>remove all ordinary codes (ctrl+o, terminates bold/color/..)</p>
+                </td>
+              </tr>
+
+              <tr valign="top">
+                <td>
+                  <p><strong>i</strong></p>
+                </td>
+
+                <td>
+                  <p>remove all italics codes</p>
+                </td>
+              </tr>
+              <tr valign="top">
+                <td>
+                  <p><strong>*</strong></p>
+                </td>
+
+                <td>
+                  <p>remove all of the above</p>
+                </td>
+              </tr>
             </table>
           </blockquote>
 
@@ -3616,21 +3644,21 @@
             <table>
               <tr valign="top">
                 <td>
-                  <p><strong>b</strong></p>
+                  <p><strong>c</strong></p>
                 </td>
 
                 <td>
-                  <p>remove all boldface codes</p>
+                  <p>remove all color codes</p>
                 </td>
               </tr>
 
               <tr valign="top">
                 <td>
-                  <p><strong>c</strong></p>
+                  <p><strong>b</strong></p>
                 </td>
 
                 <td>
-                  <p>remove all color codes</p>
+                  <p>remove all boldface codes</p>
                 </td>
               </tr>
 
@@ -3687,7 +3715,7 @@
 
               <tr valign="top">
                 <td>
-                  <p><strong>o</strong></p>
+                  <p><strong>i</strong></p>
                 </td>
 
                 <td>
Index: eggdrop1.8/doc/tcl-commands.doc
diff -u eggdrop1.8/doc/tcl-commands.doc:1.12 eggdrop1.8/doc/tcl-commands.doc:1.13
--- eggdrop1.8/doc/tcl-commands.doc:1.12	Tue Jun 26 15:20:49 2012
+++ eggdrop1.8/doc/tcl-commands.doc	Tue Jul 30 18:20:05 2013
@@ -1,4 +1,4 @@
-$Id: tcl-commands.doc,v 1.12 2012/06/26 21:20:49 thommey Exp $
+$Id: tcl-commands.doc,v 1.13 2013/07/31 00:20:05 thommey Exp $
 
 Eggdrop Tcl Commands
 Last revised: October 24, 2010
@@ -955,12 +955,15 @@
   strip <idx> [+/-strip-flags]
     Description: modifies the strip-flags for a user. The supported
       strip-flags are:
-        b - remove all boldface codes
         c - remove all color codes
+        b - remove all boldface codes
         r - remove all reverse video codes
         u - remove all underline codes
         a - remove all ANSI codes
         g - remove all ctrl-g (bell) codes
+        o - remove all ordinary codes (ctrl+o, terminates bold/color/..)
+        i - remove all italics codes
+        * - remove all of the above
     Returns: new strip-flags for the specified user (or the current
       flags, if strip-flags was omitted)
     Module: core
@@ -1589,8 +1592,8 @@
   stripcodes <strip-flags> <string>
     Description: strips specified control characters from the string given.
       strip-flags can be any combination of the following:
-        b - remove all boldface codes
         c - remove all color codes
+        b - remove all boldface codes
         r - remove all reverse video codes
         u - remove all underline codes
         a - remove all ANSI codes
Index: eggdrop1.8/help/cmds2.help
diff -u eggdrop1.8/help/cmds2.help:1.1.1.1 eggdrop1.8/help/cmds2.help:1.2
--- eggdrop1.8/help/cmds2.help:1.1.1.1	Mon Jul 26 15:11:06 2010
+++ eggdrop1.8/help/cmds2.help	Tue Jul 30 18:20:05 2013
@@ -61,7 +61,7 @@
    Specifying "&" as the separator will cause AND style matching.
 
    For example:
-      .match p&o
+      .match +p&o
 
    This will match all users with both the "p" global flag and the "o" channel
    flag on your current console channel.
@@ -69,20 +69,20 @@
    Specifying "|" as the separator will cause OR style matching.
 
    For example:
-     .match p|o
+      .match +p|o
 
    This will match all users with either the "p" global flag or the "o" channel
    flag on your current console channel. If you specify a channel, it will be
    used instead of the current console channel.
 
    For example:
-     .match p|o #eggdrop
+      .match +p|o #eggdrop
 
    This will match all users with either the "p" global flag or the "o" channel
    flag on the channel #eggdrop. You can also match bot flags.
 
    For example:
-     .match o|o|h
+      .match +o|o|h
 
    This will match all bots with either the "o" global flag, the "o" channel
    flag on the current console channel, or the "h" botflag. You can also limit
@@ -90,7 +90,7 @@
    command. A starting point can also be specified.
 
    For example:
-     .match p&o #eggdrop 16 25
+      .match +p&o #eggdrop 16 25
 
    This would show results 16 through 25 matching any users with the "p" global
    flag or the "o" channel flag on #eggdrop.
@@ -229,12 +229,15 @@
 ###  %bstrip%b [modes]
    Allows you to remove embedded 'attribute' codes your partyline output. Valid
    options are:
-      %bb%b - remove all boldface codes
       %bc%b - remove all color codes
+      %bb%b - remove all boldface codes
       %br%b - remove all reverse video codes
       %bu%b - remove all underline codes
       %ba%b - remove all ANSI codes
       %bg%b - remove all ctrl-g (bell) codes
+      %bo%b - remove all ordinary codes (ctrl+o, terminates bold/color/..)
+      %bi%b - remove all italics codes
+      %b*%b - remove all of the above
 
    The mode can also be a modifier like '+c' or '-bu' or '+ru-c'. If
    you omit modes, it will show your current setting.
Index: eggdrop1.8/src/cmds.c
diff -u eggdrop1.8/src/cmds.c:1.7 eggdrop1.8/src/cmds.c:1.8
--- eggdrop1.8/src/cmds.c:1.7	Mon Jul 29 09:49:40 2013
+++ eggdrop1.8/src/cmds.c	Tue Jul 30 18:20:05 2013
@@ -3,7 +3,7 @@
  *   commands from a user via dcc
  *   (split in 2, this portion contains no-irc commands)
  *
- * $Id: cmds.c,v 1.7 2013/07/29 15:49:40 thommey Exp $
+ * $Id: cmds.c,v 1.8 2013/07/31 00:20:05 thommey Exp $
  */
 /*
  * Copyright (C) 1997 Robey Pointer
@@ -2000,30 +2000,30 @@
 
   for (; *s; s++)
     switch (tolower((unsigned) *s)) {
-    case 'b':
-      res |= STRIP_BOLD;
-      break;
     case 'c':
       res |= STRIP_COLOR;
       break;
+    case 'b':
+      res |= STRIP_BOLD;
+      break;
     case 'r':
       res |= STRIP_REVERSE;
       break;
     case 'u':
       res |= STRIP_UNDERLINE;
       break;
-    case 'i':
-      res |= STRIP_ITALICS;
-      break;
-    case 'o':
-      res |= STRIP_ORDINARY;
-      break;
     case 'a':
       res |= STRIP_ANSI;
       break;
     case 'g':
       res |= STRIP_BELLS;
       break;
+    case 'o':
+      res |= STRIP_ORDINARY;
+      break;
+    case 'i':
+      res |= STRIP_ITALICS;
+      break;
     case '*':
       res |= STRIP_ALL;
       break;
@@ -2036,22 +2036,22 @@
   static char s[20];
   char *p = s;
 
-  if (x & STRIP_BOLD)
-    *p++ = 'b';
   if (x & STRIP_COLOR)
     *p++ = 'c';
+  if (x & STRIP_BOLD)
+    *p++ = 'b';
   if (x & STRIP_REVERSE)
     *p++ = 'r';
-  if (x & STRIP_ITALICS)
-    *p++ = 'i';
-  if (x & STRIP_ORDINARY)
-    *p++ = 'o';
   if (x & STRIP_UNDERLINE)
     *p++ = 'u';
   if (x & STRIP_ANSI)
     *p++ = 'a';
   if (x & STRIP_BELLS)
     *p++ = 'g';
+  if (x & STRIP_ORDINARY)
+    *p++ = 'o';
+  if (x & STRIP_ITALICS)
+    *p++ = 'i';
   if (p == s)
     *p++ = '-';
   *p = 0;
@@ -2064,22 +2064,22 @@
   int i = 0;
 
   s[i] = 0;
-  if (x & STRIP_BOLD)
-    i += my_strcpy(s + i, "bold, ");
   if (x & STRIP_COLOR)
     i += my_strcpy(s + i, "color, ");
+  if (x & STRIP_BOLD)
+    i += my_strcpy(s + i, "bold, ");
   if (x & STRIP_REVERSE)
     i += my_strcpy(s + i, "reverse, ");
   if (x & STRIP_UNDERLINE)
     i += my_strcpy(s + i, "underline, ");
-  if (x & STRIP_ITALICS)
-    i += my_strcpy(s + i, "italics, ");
-  if (x & STRIP_ORDINARY)
-    i += my_strcpy(s + i, "ordinary, ");
   if (x & STRIP_ANSI)
     i += my_strcpy(s + i, "ansi, ");
   if (x & STRIP_BELLS)
     i += my_strcpy(s + i, "bells, ");
+  if (x & STRIP_ORDINARY)
+    i += my_strcpy(s + i, "ordinary, ");
+  if (x & STRIP_ITALICS)
+    i += my_strcpy(s + i, "italics, ");
   if (!i)
     strcpy(s, "none");
   else
Index: eggdrop1.8/src/dcc.c
diff -u eggdrop1.8/src/dcc.c:1.13 eggdrop1.8/src/dcc.c:1.14
--- eggdrop1.8/src/dcc.c:1.13	Fri Jun 22 17:35:33 2012
+++ eggdrop1.8/src/dcc.c	Tue Jul 30 18:20:05 2013
@@ -4,7 +4,7 @@
  *   disconnect on a dcc socket
  *   ...and that's it!  (but it's a LOT)
  *
- * $Id: dcc.c,v 1.13 2012/06/22 23:35:33 thommey Exp $
+ * $Id: dcc.c,v 1.14 2013/07/31 00:20:05 thommey Exp $
  */
 /*
  * Copyright (C) 1997 Robey Pointer
@@ -795,12 +795,6 @@
 
   while (*text) {
     switch (*text) {
-    case 2:                    /* Bold text */
-      if (flags & STRIP_BOLD) {
-        text++;
-        continue;
-      }
-      break;
     case 3:                    /* mIRC colors? */
       if (flags & STRIP_COLOR) {
         if (egg_isdigit(text[1])) { /* Is the first char a number? */
@@ -818,14 +812,8 @@
         continue;
       }
       break;
-    case 7:
-      if (flags & STRIP_BELLS) {
-        text++;
-        continue;
-      }
-      break;
-    case 017:                  /* Ordinary (mIRC ctrl+o) */
-      if (flags & STRIP_ORDINARY) {
+    case 2:                    /* Bold text */
+      if (flags & STRIP_BOLD) {
         text++;
         continue;
       }
@@ -836,12 +824,6 @@
         continue;
       }
       break;
-    case 29:                   /* Italics */
-      if (flags & STRIP_ITALICS) {
-        text++;
-        continue;
-      }
-      break;
     case 0x1f:                 /* Underlined text */
       if (flags & STRIP_UNDERLINE) {
         text++;
@@ -861,6 +843,24 @@
         continue;
       }
       break;
+    case 7:
+      if (flags & STRIP_BELLS) {
+        text++;
+        continue;
+      }
+      break;
+    case 017:                  /* Ordinary (mIRC ctrl+o) */
+      if (flags & STRIP_ORDINARY) {
+        text++;
+        continue;
+      }
+      break;
+    case 29:                   /* Italics */
+      if (flags & STRIP_ITALICS) {
+        text++;
+        continue;
+      }
+      break;
     }
     *dd++ = *text++;            /* Move on to the next char */
   }
Index: eggdrop1.8/src/tclmisc.c
diff -u eggdrop1.8/src/tclmisc.c:1.7 eggdrop1.8/src/tclmisc.c:1.8
--- eggdrop1.8/src/tclmisc.c:1.7	Fri Jun 22 17:35:33 2012
+++ eggdrop1.8/src/tclmisc.c	Tue Jul 30 18:20:05 2013
@@ -2,7 +2,7 @@
  * tclmisc.c -- handles:
  *   Tcl stubs for everything else
  *
- * $Id: tclmisc.c,v 1.7 2012/06/22 23:35:33 thommey Exp $
+ * $Id: tclmisc.c,v 1.8 2013/07/31 00:20:05 thommey Exp $
  */
 /*
  * Copyright (C) 1997 Robey Pointer
@@ -663,29 +663,29 @@
 
   for (p = argv[1]; *p; p++)
     switch (*p) {
-    case 'a':
-      flags |= STRIP_ANSI;
+    case 'c':
+      flags |= STRIP_COLOR;
       break;
     case 'b':
       flags |= STRIP_BOLD;
       break;
-    case 'c':
-      flags |= STRIP_COLOR;
+    case 'r':
+      flags |= STRIP_REVERSE;
       break;
-    case 'o':
-      flags |= STRIP_ORDINARY;
+    case 'u':
+      flags |= STRIP_UNDERLINE;
       break;
-    case 'i':
-      flags |= STRIP_ITALICS;
+    case 'a':
+      flags |= STRIP_ANSI;
       break;
     case 'g':
       flags |= STRIP_BELLS;
       break;
-    case 'r':
-      flags |= STRIP_REVERSE;
+    case 'o':
+      flags |= STRIP_ORDINARY;
       break;
-    case 'u':
-      flags |= STRIP_UNDERLINE;
+    case 'i':
+      flags |= STRIP_ITALICS;
       break;
     case '*':
       flags |= STRIP_ALL;
----------------------- End of diff -----------------------


More information about the Changes mailing list