Skip to content

Instantly share code, notes, and snippets.

@jdorfman
Created March 22, 2012 16:27
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 jdorfman/2159366 to your computer and use it in GitHub Desktop.
Save jdorfman/2159366 to your computer and use it in GitHub Desktop.
# Echo a Range
echo 192.168.0.{2..102} > file.txt
# Replace spaces with newlines
tr ' ' '\n' < file.txt
# Remove a line (386) from a file
sed -i '386d' .ssh/known_host
# Remove 2 lines (22 & 36)
sed -i '22,36d' .ssh/known_host
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment