Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@leftclickben
Created December 7, 2015 07:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save leftclickben/f41a9a21637f5dbb33d6 to your computer and use it in GitHub Desktop.
Save leftclickben/f41a9a21637f5dbb33d6 to your computer and use it in GitHub Desktop.
strip-referer
#!/bin/bash
# http://nigel.mcnie.name/blog/removing-the-referer-part-of-php-error-messagse-from-apache-logs
perl -pe 's/\s+\[\:error\]\s+\[pid\s+\d+\]\s+\[client\s+.*?\]//; s/, referer:.*//'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment