home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.msdos.batch.nt      Fun with Windows NT batch files      68,980 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 67,618 of 68,980   
   Kerr-Mudd,John to Mike Sanders   
   Re: every-10-days.cmd   
   08 Aug 20 09:01:51   
   
   d640a330   
   From: notsaying@127.0.0.1   
      
   On Thu, 06 Aug 2020 19:10:23 GMT, Mike Sanders  wrote:   
      
   > Kerr-Mudd,John writes:   
   >   
   >>On Thu, 06 Aug 2020 17:21:12 GMT, Mike Sanders  wrote:   
   >>   
   >>>   
   >>> Nice 'bit of kit' here. Allows you run your script   
   >>> only on certain days. Just using plain 'ol modulus.   
   >>   
   >>It wasn't around when batch 1st started; No arithmetic at all, IIRC!   
   >   
   > (Hoping this article is threaded properly as I'm using an ancient   
   > news reader.)   
   >   
   > Funny isn't it? Computers are simply oversized calculators after all...   
   >   
   >>Why would I want to run program on the 1st when I just ran it yesterday   
   >>/a day ago?   
   >   
   > Mmm, well here I need % 10 for some automated .log & .csv processing.   
   >   
   >>More useful might be to run weekly; in which case check the day number.   
   >   
   > Sure enough, jump right in & build it John! Maybe something like, oh I   
   > dunno:   
   >   
   > if %date:~0,3%=="Mon" then...   
   >   
   I looked into this ; not all Locales/OS show the day string.   
   Given my retro outlook I'd use a debug asm helper. No good in W10!   
      
   Here's something I wrote in 1990; I'd use a temp dir now!   
   @echo off   
   echo nqday.com>qday.dbg   
   echo rcx>>qday.dbg   
   echo 30>>qday.dbg   
   echo e100 B4'*'CD'!'B4'LP'B4 0 8B F0 BA' '1 D1 E6>>qday.dbg   
   echo e110 3 F2 8A 14 B4 2 CD'!'8A'T'1 CD'!X'CD'!'>>qday.dbg   
   echo e120 'SuMoTuWeThFrSa'                       >>qday.dbg   
   echo w>>qday.dbg   
   echo q>>qday.dbg   
   debug nul   
   qday2   
   echo.   
   del qday.*   
      
   [Int 2A gives daynum]   
   --   
   Bah, and indeed, Humbug.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca