Skip to content

Instantly share code, notes, and snippets.

@coderofsalvation
Created January 10, 2014 12:49
Show Gist options
  • Select an option

  • Save coderofsalvation/8351389 to your computer and use it in GitHub Desktop.

Select an option

Save coderofsalvation/8351389 to your computer and use it in GitHub Desktop.
highlights keywords in bashcode script
# highlights keywords in bashcode script
# usage: echo "foo normal bar" | highlight "foo|bar"
highlight(){
cat - | grep -E --color "$1"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment