added extra callsigns to the end of the reply command so that I can reply
authordjk <djk>
Wed, 26 Apr 2000 13:20:58 +0000 (13:20 +0000)
committerdjk <djk>
Wed, 26 Apr 2000 13:20:58 +0000 (13:20 +0000)
to several people all at once

Changes
cmd/Commands_en.hlp
cmd/reply.pl

diff --git a/Changes b/Changes
index d0301f3d73e810326f9a930edf2fbe2e6a5995a8..5b9060d0197a4016248e8a334b10ff72e6b9ac4e 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,10 +1,12 @@
+25Apr00=======================================================================
+1. Changed reply so that you can reply to more than one address privately
 31Mar00=======================================================================
 1. fixed nnn-mmm in kill (erase/delete) msgs so that mmm is also deleted and
 not just nnn -> mmm-1.
 2. Added an autosplit to message importing so that messages are split
 automagically into bits if the filename used in the import directory starts
 with "split". This will add a [1/5] type string on the the end of the subject. 
-3. dedupe more aggressively on the text of Spots so that only the 1st 28 chars
+3. dedupe more aggressively on the text of Spots so that only the 1st 27 chars
 of text are considered (as opposed to the whole lot).
 30Mar00=======================================================================
 1. altered client.pl connect code so that it doesn't falsely recognise 
index f1272ee9e418a3ac2467eb731c119227f890a3fb..f0acc321229c06d5139ccc22d7415e70bdd72bbf 100644 (file)
@@ -389,6 +389,12 @@ You can also use all the extra qualifiers such as RR, PRIVATE,
 NOPRIVATE, B that you can use with the SEND command (see SEND
 for further details)
 
+You can also send a copy of this message to a number of other callsigns
+(if and only if the reply is private) by adding the callsigns to the
+end of the reply command you want to use e.g:-
+
+  REPLY 2345 G1TLH G7BRN
+
 === 0^SEND <call> [<call> ...]^Send a message to one or more callsigns
 === 0^SEND RR <call>^Send a message and ask for a read receipt
 === 0^SEND COPY <msgno> <call>^Send a copy of a  message to someone
index 6982eb599e57993faf17a618f292388c83e4b846..54b52dba9f751cb3348016ca66683b3954eed47d 100644 (file)
@@ -31,44 +31,45 @@ if ($self->state eq "prompt") {
        $loc = $self->{loc} = {};
        
        my $i = 0;
+       my @extra = ();
+       my $msgno = $self->lastread;
        $loc->{private} = '1';
-       if ($i < @f) {
-               if ($f[0] =~ /^(B|NOP)/oi) {
+       $loc->{rrreq} = '0';
+       while (@f) {
+               my $w = shift @f;
+               if ($w =~ /^\d+$/) {
+                       $msgno = $w;
+               } elsif ($w =~ /^(B|NOP)/i) {
                        $loc->{private} = '0';
-                       $i += 1;
-               } elsif ($f[0] =~ /^P/oi) {
-                       $i += 1;
-               }
-       }
-       
-       if ($i < @f) {
-               $loc->{rrreq} = '0';
-               if (uc $f[$i] eq 'RR') {
+               } elsif ($w =~ /^P/i) {
+                       ;
+               } elsif (uc $w eq 'RR') {
                        $loc->{rrreq} = '1';
-                       $i++;
+               } else {
+                       push @extra, uc $w;
                }
        }
+       
        my $oref; 
        
        # check we have a reply number
        #  $DB::single = 1;
        
-       if ($i < @f) {
-               $oref = DXMsg::get($f[$i]);
-               if (!$oref) {
-                       delete $self->{loc};
-                       return (1, $self->msg('m4', $i));
-               }
-       } else {
-               if (!($oref = DXMsg::get($self->lastread))) {
-                       delete $self->{loc};
-                       return (1, $self->msg('m5'));
-               }
+       $oref = DXMsg::get($msgno) if $msgno;
+       unless ($oref) {
+               delete $self->{loc};
+               return (1, $self->msg('m4', $i));
        }
        
        # now save all the 'to' callsigns for later
-       my $to = $loc->{private} ? $oref->from : $oref->to;
-       $loc->{to} = [ $to ];       # to is an array
+       my $to;
+       if ($loc->{private}) {
+               $to = $oref->from;
+       } else {
+               $to = $oref->to;
+               @extra = ();
+       } 
+       $loc->{to} = [ $to, @extra ];       # to is an array
        $loc->{subject} = $oref->subject;
        $loc->{subject} = "Re: " . $loc->{subject} if !($loc->{subject} =~ /^Re:\s/io); 
        
@@ -76,7 +77,7 @@ if ($self->state eq "prompt") {
        # keep calling me for every line until I relinquish control
        $self->func("DXMsg::do_send_stuff");
        $self->state('sendbody');
-       push @out, $self->msg('m6', $to);
+       push @out, $self->msg('m6', join(',', $to, @extra));
        push @out, $self->msg('m7', $loc->{subject});
        push @out, $self->msg('m8');
 }