Created
April 11, 2019 07:40
-
-
Save mcnemesis/b041eaefcfbd7030f41c362799d5dbee to your computer and use it in GitHub Desktop.
for those times you need a handy utility to preview logs on the way to doing other things...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# nuchwezilabs ## for those times you need a handy utility to preview logs on the way to doing other things... | |
#alias lastlog="tail -n 20 $(ls -d -t -1 "$PWD/logs/"** | sed -n '2p')" | |
#nu method... | |
function lastlog() { | |
tail -n 20 $(ls -d -t -1 $(pwd)/logs/** | sed -n '2p') | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment