New answers tagged

1

You can edit the file, but the entries added to the file while you edit it are lost, because the editor loads the log file into memory, and saves the file from memory to disk after editing. However, you can move the log file to another file with mv command, reload webserver, and then edit the other file. This way no entries are lost. Webserver starts to ...


0

If you don't care about the filename, you can delegate this task to a utility, for example mktemp Create a temporary file or directory, safely, and print its name. TEMPLATE must contain at least 3 consecutive `X's in last component. If TEMPLATE is not specā€ified, use tmp.XXXXXXXXXX, and --tmpdir is implied. Files are created u+rw, and directories u+rwx, ...


0

Much better answers here; http://superuser.com/questions/61611/how-to-copy-with-cp-to-include-hidden-files-and-hidden-directories-and-their-con It describes for example using shopt for a native bash solution



Top 50 recent answers are included