1

I am running Windows 10, with Cygwin. I also have 4NT installed and can use commands from that if it helps.

I usually open files for editing via the command line.

I would like, for one particular file, to implement an automatic delay before it open. So that if I type vi FILENAME, FILENAME will open not immediately but fifteen minutes later. (Yes, I realize this probably sounds crazy.)

Is there a way to do that?

Giacomo1968
  • 58,727

1 Answers1

1

Okay, got it:

if "%1" = "xxx" delayopen %1

if "%1" != "xxx" \cygwin64\bin\vi.exe %1

where delayopen.bat is:

sleep 900

call c:\cygwin64\bin\vi.exe %1

What I wasn't aware of was the "sleep" command.