On Fri, 13 Mar 2015, 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.

I don't think it's new or bash only, I've seen it in some quite old stuff.

There are always new tricks to learn, no matter how long you've been at this stuff.

David Lang
_______________________________________________
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/

Reply via email to