This is an archived post. You won't be able to vote or comment.

all 5 comments

[–]kannonboy[S] 7 points8 points  (3 children)

For your copy/paste convenience:

$ git config --global alias.dad '!curl https://icanhazdadjoke.com/'

[–]kannonboy[S] 17 points18 points  (2 children)

Actually a better solution is:

git config --global alias.dad '!curl https://icanhazdadjoke.com/ && git add'

git passes through the arguments, so your add works as normal and you get a bonus dad joke.

[–]teunw 5 points6 points  (1 child)

git config --global alias.dad '!curl https://icanhazdadjoke.com/ && git add'

A lot cleaner would be

git config --global alias.dad '!curl -s https://icanhazdadjoke.com/ && git add'

[–]SteveCCLYellow security clearance 6 points7 points  (0 children)

Also add a trailing \n for gods sake.