From: "Massimo S." Received: from [192.168.100.201] (HELO mail.2rosenthals.com) by 2rosenthals.com (CommuniGate Pro SMTP 5.4.10) with ESMTP id 14423412 for ecs-isp@2rosenthals.com; Tue, 14 Oct 2025 15:37:05 -0400 Received: from [192.168.200.201] (port=60040 helo=mail2.2rosenthals.com) by mail.2rosenthals.com with esmtp (Exim 4.98.2) (envelope-from ) id 1v8kpS-000000004Qu-1vC5 for ecs-isp@2rosenthals.com; Tue, 14 Oct 2025 15:37:04 -0400 Received: from mail2.quasarbbs.net ([80.86.52.115]:10126) by mail2.2rosenthals.com with esmtp (Exim 4.98.2) (envelope-from ) id 1v8kpP-000000002pv-0DmG for ecs-isp@2rosenthals.com; Tue, 14 Oct 2025 15:37:00 -0400 X-SASI-Hits: BODYTEXTP_SIZE_3000_LESS 0.000000, BODY_SIZE_1700_1799 0.000000, BODY_SIZE_2000_LESS 0.000000, BODY_SIZE_5000_LESS 0.000000, BODY_SIZE_7000_LESS 0.000000, CTE_7BIT 0.000000, DKIM_ALIGNS 0.000000, DKIM_SIGNATURE 0.000000, HTML_00_01 0.050000, HTML_00_10 0.050000, IN_REP_TO 0.000000, LEGITIMATE_SIGNS 0.000000, MSGID_SAMEAS_FROM_HEX_844412 0.100000, MSG_THREAD 0.000000, NO_CTA_URI_FOUND 0.000000, NO_URI_HTTPS 0.000000, REFERENCES 0.000000, REPLYTO_SAMEAS_FROM 0.000000, SENDER_NO_AUTH 0.000000, SUSP_DH_NEG 0.000000, TO_IN_SUBJECT 0.500000, USER_AGENT 0.000000, __ANY_URI 0.000000, __BODY_NO_MAILTO 0.000000, __BOUNCE_CHALLENGE_SUBJ 0.000000, __BOUNCE_NDR_SUBJ_EXEMPT 0.000000, __CT 0.000000, __CTE 0.000000, __CT_TEXT_PLAIN 0.000000, __DKIM_ALIGNS_1 0.000000, __DKIM_ALIGNS_2 0.000000, __DQ_NEG_DOMAIN 0.000000, __DQ_NEG_HEUR 0.000000, __DQ_NEG_IP 0.000000, __FORWARDED_MSG 0.000000, __FROM_DOMAIN_NOT_IN_BODY 0.000000, __FROM_NAME_NOT_IN_ADDR 0.000000, __FROM_NAME_NOT_IN_BODY 0.000000, __FUR_HEADER 0.000000, __HAS_FROM 0.000000, __HAS_MSGID 0.000000, __HAS_REFERENCES 0.000000, __HAS_REPLYTO 0.000000, __HEADER_ORDER_FROM 0.000000, __IN_REP_TO 0.000000, __IOC_PHRASE 0.000000, __MAIL_CHAIN 0.000000, __MIME_BOUND_CHARSET 0.000000, __MIME_TEXT_ONLY 0.000000, __MIME_TEXT_P 0.000000, __MIME_TEXT_P1 0.000000, __MIME_VERSION 0.000000, __MOZILLA_USER_AGENT 0.000000, __MSGID_HEX_844412 0.000000, __NO_HTML_TAG_RAW 0.000000, __PHISH_SPEAR_SUBJ_SUBJECT 0.000000, __REFERENCES 0.000000, __REPLYTO_SAMEAS_FROM_ACC 0.000000, __REPLYTO_SAMEAS_FROM_ADDY 0.000000, __REPLYTO_SAMEAS_FROM_DOMAIN 0.000000, __SANE_MSGID 0.000000, __SCAN_D_NEG 0.000000, __SCAN_D_NEG2 0.000000, __SCAN_D_NEG_HEUR 0.000000, __SCAN_D_NEG_HEUR2 0.000000, __SUBJ_ALPHA_END 0.000000, __SUBJ_ALPHA_NEGATE 0.000000, __SUBJ_REPLY 0.000000, __TO_IN_SUBJECT 0.000000, __TO_MALFORMED_2 0.000000, __TO_NAME 0.000000, __TO_NAME_DIFF_FROM_ACC 0.000000, __TO_REAL_NAMES 0.000000, __URI_MAILTO 0.000000, __URI_NO_WWW 0.000000, __URI_NS 0.000000, __USER_AGENT 0.000000 X-SASI-Probability: 10% X-SASI-RCODE: 200 X-SASI-Version: Antispam-Engine: 5.1.4, AntispamData: 2025.10.14.185719 X-SASI-Hits: BODYTEXTP_SIZE_3000_LESS 0.000000, BODY_SIZE_1700_1799 0.000000, BODY_SIZE_2000_LESS 0.000000, BODY_SIZE_5000_LESS 0.000000, BODY_SIZE_7000_LESS 0.000000, CTE_7BIT 0.000000, DKIM_ALIGNS 0.000000, DKIM_SIGNATURE 0.000000, HTML_00_01 0.050000, HTML_00_10 0.050000, IN_REP_TO 0.000000, LEGITIMATE_SIGNS 0.000000, MSGID_SAMEAS_FROM_HEX_844412 0.100000, MSG_THREAD 0.000000, NO_CTA_URI_FOUND 0.000000, NO_URI_HTTPS 0.000000, REFERENCES 0.000000, REPLYTO_SAMEAS_FROM 0.000000, SUSP_DH_NEG 0.000000, TO_IN_SUBJECT 0.500000, USER_AGENT 0.000000, __ANY_URI 0.000000, __AUTH_RES_PASS 0.000000, __BODY_NO_MAILTO 0.000000, __BOUNCE_CHALLENGE_SUBJ 0.000000, __BOUNCE_NDR_SUBJ_EXEMPT 0.000000, __CT 0.000000, __CTE 0.000000, __CT_TEXT_PLAIN 0.000000, __DKIM_ALIGNS_1 0.000000, __DKIM_ALIGNS_2 0.000000, __DQ_NEG_DOMAIN 0.000000, __DQ_NEG_HEUR 0.000000, __DQ_NEG_IP 0.000000, __FORWARDED_MSG 0.000000, __FROM_DOMAIN_NOT_IN_BODY 0.000000, __FROM_NAME_NOT_IN_ADDR 0.000000, __FROM_NAME_NOT_IN_BODY 0.000000, __FUR_HEADER 0.000000, __HAS_FROM 0.000000, __HAS_MSGID 0.000000, __HAS_REFERENCES 0.000000, __HAS_REPLYTO 0.000000, __HEADER_ORDER_FROM 0.000000, __IN_REP_TO 0.000000, __IOC_PHRASE 0.000000, __MAIL_CHAIN 0.000000, __MIME_BOUND_CHARSET 0.000000, __MIME_TEXT_ONLY 0.000000, __MIME_TEXT_P 0.000000, __MIME_TEXT_P1 0.000000, __MIME_VERSION 0.000000, __MOZILLA_USER_AGENT 0.000000, __MSGID_HEX_844412 0.000000, __NO_HTML_TAG_RAW 0.000000, __PHISH_SPEAR_SUBJ_SUBJECT 0.000000, __REFERENCES 0.000000, __REPLYTO_SAMEAS_FROM_ACC 0.000000, __REPLYTO_SAMEAS_FROM_ADDY 0.000000, __REPLYTO_SAMEAS_FROM_DOMAIN 0.000000, __SANE_MSGID 0.000000, __SCAN_D_NEG 0.000000, __SCAN_D_NEG2 0.000000, __SCAN_D_NEG_HEUR 0.000000, __SCAN_D_NEG_HEUR2 0.000000, __SUBJ_ALPHA_END 0.000000, __SUBJ_ALPHA_NEGATE 0.000000, __SUBJ_REPLY 0.000000, __TO_IN_SUBJECT 0.000000, __TO_MALFORMED_2 0.000000, __TO_NAME 0.000000, __TO_NAME_DIFF_FROM_ACC 0.000000, __TO_REAL_NAMES 0.000000, __URI_MAILTO 0.000000, __URI_NO_WWW 0.000000, __URI_NS 0.000000, __USER_AGENT 0.000000 X-SASI-Probability: 10% X-SASI-RCODE: 200 X-SASI-Version: Antispam-Engine: 5.1.4, AntispamData: 2025.10.14.185719 DKIM-Signature: v=1; q=dns/txt; a=rsa-sha256; c=relaxed/relaxed; s=default; d=ecomstation.it; bh=IFQA/xx7KDwmEtjIhjlo3a9qAV00+3bzXh4H/OeioAA=; h=Return-Path:From:To:Subject:Date:Message-ID; b=F4sGaXxNfk0xBCpcHeiEWVHTaDxQ5vMoIsFD7MqxeUCsCb/BiECkokr6kIB71rMI4uFPF 0dpDY+D5xIqpZiomyRPXF4yjw/AHi4T/WVE52bUAy9DHFlldUrtI90yXPcGGf1IjUpRjQfL tZWIAAmNQXSqXz99NRlm/2OrHd2IJ+7nfWGgBZZ4cHAzgCorT0K8u8MpJf0Xv1lkPcnWjTL XSOOFvoSGgH/4aPW/DgvZjQxMenssM22v1efmMeyg6kAcfWyuOc/WFIT7NZVDev13zXBmq3 TWUbOYUTluehpMGBy0ZKMZdRqQCtnSWvDXG36R8cSVHzz7rlD3lqrnIuJoEw== Received: from [192.168.10.199] (dtp [192.168.10.199]) by srv2 (Weasel v3.08) for ; Tue, 14 Oct 2025 21:36:57 -0000 Reply-To: ml@ecomstation.it Subject: Re: [eCS-ISP] script to rotate logs, old mails etc. and create a dated zip To: eCS ISP Mailing List References: Organization: Massimo S. Message-ID: <2fcc39af-0874-ad9e-6838-d55c4d4be883@ecomstation.it> Date: Tue, 14 Oct 2025 21:36:50 +0200 User-Agent: Mozilla/5.0 (OS/2; U; Warp 4.5; it-IT; rv:1.7.13) Gecko/20060424 Thunderbird/1.0.8 Mnenhy/0.7.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=iso-8859-15; format=flowed Content-Language: it Content-Transfer-Encoding: 7bit Il 14/10/2025 22:07, Steven Levine ha scritto: > In , on 10/14/25 > at 09:15 AM, "Massimo S." said: > > Hi, > >> I need to move to a zip archive (with the current date in the filename), >> all the .MSG files older than a certain date (eg. 365 days). > > OK. Peter did a better job of understanding your request than I did. > >> I'm not able to write it myself. > > Sure you can. The others have provided useful suggestions. The help > yourself with the coding and debugging, you need to use the available > tools. The REXX say and trace statements are your friends. There's also > rxd which is a gui debugger for REXX. > > My scripts also turn on all the available error checking signals. I am a > firm believer in letting my tools do as much of the debugging as they are > capable of. > >> And all the stuff produced by Copilot is in a rexx that do not work >> properly, maybe it's regina rexx, but it's not compatible with our one. > > Did you tell Copolit that you wanted a "IBM Classic REXX" script? If you > only asked for a REXX script, there's no way for Copilot to know what you > really need. I doubt Copilot yet can read your mind. I've specified OS/2 rexx, but afaik AI is not so much intelligent. :D > REXX, especally Classic REXX, is not all to good with handling date > ranges. If would probably use 4OS2. Since you run cmd.exe, something > lile > > 4os2 /c dir /b /a:-d /[d-365,1-1-80] *.msg >oldfiles.nf > zip -uo9 -m -@ oldfiles.zip > will work once you debug it and correct any typos I might have provided. > > Plug this into your REXX script that generates the zip file name and you > are close to done. > > Steven Thanks for the hint, i will try. massimo