taskWeeChat - Tasks: task #11732, new function to avoid sending...

 
 

task #11732: new function to avoid sending unwanted commands as PRIVMSG

Submitter:  nesthib <nesthib>
Submitted:  Thu 12 Jan 2012 12:26:29 PM UTC
   
 
Category:  commands Should Start On:  Thu 12 Jan 2012 12:00:00 AM UTC
Should be Finished on:  Thu 12 Jan 2012 12:00:00 AM UTC Priority:  * 5 - Normal
Status:  Cancelled Privacy:  Public
Assigned to:  flashcode Percent Complete:  0%
Originator Name:  Open/Closed:  Closed
Planned Release:  None IRC nick:  nesthib
* Mandatory Fields

Add a New Comment Rich Markup
   

Wed 22 Aug 2012 12:30:23 PM UTC, comment #1: 

Possible with script unwanted_msg.py

Sebastien Helleu <flashcode>
Group administrator
Thu 12 Jan 2012 12:26:29 PM UTC, original submission:  

I suggest a new function to avoid sending unwanted commands as PRIVMSG in channel buffers. There should be an option to detect input starting with spaces then / and warn the user.
As for the option weechat.look.paste_max_lines, when pressing enter after writing a line starting with blanks then "/", weechat should ask something like:
[send ctrl+y] [cancel ctrl+n] [strip blanks ctrl+…]

where "send" would force sending the message, "cancel" would allow to come back to prompt and modify the line and "strip" would remove the unwanted characters (i.e. exec the command and not send PRIVMSG)

An option (boolean) should be added to allow the function to be enabled/disabled.

further idea (optional):
An other option (string) may be added to allow the customization of the regexp used to detect the pattern.
e.g. "( +)/.*" would mean that warning is displayed for lines starting with blanks then / then anything, and the parenthesis would define the pattern to be removed.
This would allow to define more generic patterns as "([a-Z ])/.*nickserv.*"

or maybe the string should just consider the pattern to be removed and be detected if being before the first "/" of the input (so would be just " *" or "([a-Z ])")

nesthib <nesthib>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by flashcode (Posted a comment)
  • -email is unavailable- added by nesthib (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2012-09-29 flashcode Open/ClosedOpen Closed
    2012-08-22 flashcode StatusNone Cancelled
        Assigned toNone flashcode

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code