Tag Info

Hot answers tagged


Since you're editing the remote file in place, you don't need to capture the output, so system would be preferable than using backticks: system 'ssh', '', 'perl', '-pi.bup', '-e', 's/^(\s+?kernel)(.*)(?<!audit=1)$/$1$2 audit=1/', '/etc/grub.conf'; Note that you don't have to pass the remote command as a single parameter to ssh. That helps ...


The most reliable syntax checker is Apache itself. If you can handle 500ms of possible downtime (the time it takes to make an http request to localhost, very approximately) then do this: Make a backup of the current htaccess file Replace the current htaccess file with the file to be tested Make a request to the server, for example "curl localhost" If ...

Only top voted, non community-wiki answers of a minimum length are eligible