0 votes
18 views
in Linux by
I am a developer and most of the I need to clear log files to test my applications, eg: I need to clear laravel.log, and I have to access the file and delete the content manually, is there any way we can do it easily

1 Answer

0 votes
by
You can use the echo command to empty a file, if you want to clear laravel.log then use below command, access the file location using the command "cd" then use

echo " " > laravel.log

It will remove all the log entries and make it an empty file
...