Skip to content

Instantly share code, notes, and snippets.

@dantewang
Last active August 29, 2015 14:02
Show Gist options
  • Save dantewang/e75af74d97f266d16fdd to your computer and use it in GitHub Desktop.
Save dantewang/e75af74d97f266d16fdd to your computer and use it in GitHub Desktop.
One-line bash commands
# Bulk replace string in files:
sed -i "s/oldString/newString/g" `grep oldString -rl /path`
# Extract Tomcat pid from jps output
jps -m | grep Bootstrap | grep -o -E "[[:digit:]]*"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment