git add All Markdown Images
Here’s a one-liner you can run on a Markdown file and have all of the references images added to git. (Yes, I know git isn’t great for binary files, but still useful.)
grep "\!\[\(\)\]" README.md | sed 's/.*(\(.*\))/\1/' | xargs git add