Skip to content

Instantly share code, notes, and snippets.

View markmorlino's full-sized avatar

Mark Morlino markmorlino

View GitHub Profile
Starting a list of random things that I have found useful but can't always seem to remember and got tired of re-creating them over and over again.
# quickly use ping to see what is responding on a subnet (for when you just don't have the right tools on hand)
for I in 192.168.1.{1..254} ; do ping -c 1 $I >/dev/null 2>&1 && echo "$I answers pings" & done 2>&1 | grep answers | grep -v Exit
# quickly clean up a bunch of docker images (I think docker might have finally added somethign to do this)
docker rmi -f $(docker image ls | grep -v REPOSITORY | awk '{print $3}')
# delete an old cached host key, if it complains about line 123
sed -i 123d ~/.ssh/known_hosts

Keybase proof

I hereby claim:

  • I am markmorlino on github.
  • I am markmorlinosb (https://keybase.io/markmorlinosb) on keybase.
  • I have a public key ASC_sp7XmT2uRkdilYHESUxIKyZVdX9jI_n1-BVVlVvwqwo

To claim this, I am signing this object: