ZTree.com  | ZEN  | About...  

 Index   Back

[Help!] Touch command?   [Help!]

By: Ron Metzger       
Date: Mar 01,2018 at 17:42
In Response to: [Help!] Touch command? (John Leslie)

> I may have forgotten, but is there a way to create a size zero file
> with a user specified name?
> Thanks!

From the command line:

echo( 2>Filename.txt
. or
echo. 2>Filename.txt
. or
echo 1>NUL 2>Filename.txt

Strategy: issue a command without errors, with redirection, ignoring StdOut (1) and to (non-error) to StdErr (2) to the file (Filename.txt).

Hope this helps
Ron Metzger

982 views      
Thread locked
 

Messages in this Thread

 
96,637 Postings in 12,231 Threads, 350 registered users, 58 users online (0 registered, 58 guests)
Index | Admin contact |   Forum Time: Mar 28, 2024 - 7:07 pm UTC  |  Hits:62,376,932  (29,329 Today )
RSS Feed