The UNIX and Linux Forums
>
Top Forums
>
Shell Programming and Scripting
How to empty a file(already created)
User Name
Remember Me?
Password
Google UNIX.COM
Forums
Directory
Register
Forum Rules
FAQ
Contribute
Members List
Search
Today's Posts
Mark Forums Read
Thread
:
How to empty a file(already created)
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
#
4
(
permalink
)
07-04-2007
porter
Registered User
Join Date: Jan 2007
Posts: 2,965
Quote:
Originally Posted by
laknar
i need to empty a file which is already existing.
cat </dev/null >file
porter
View Public Profile
Find all posts by porter