Huh.. didn't know either of those.
I've always done:
echo > /path/to/filename
Paul
On 3/13/2015 11:00 AM, Robert Hajime Lanning wrote:
I tend to use:
: > filename
Since ":" is no-op.
On 03/13/15 10:54, Yves Dorfsman wrote:
For the past 25 years or so, I've always used:
cat /dev/null >/path/to/filename
to empty a file. Somebody just showed me:
>/path/to/filename
Is this "new"? I've never seen it before (and I've worked with quite
a few
sysadmins and devs)... Is this bash vs other shells? I feel weird not
knowing
this.
_______________________________________________
Tech mailing list
Tech@lists.lopsa.org
https://lists.lopsa.org/cgi-bin/mailman/listinfo/tech
This list provided by the League of Professional System Administrators
http://lopsa.org/