how to ignore folder when using adb push I like to copy development files (ie a git repo) from my local machine to my android using adb push (I still couldn't find a reliable git client application on android). 

However, I also need to ignore certain directories (think of the directories that are typically ignored by git and placed in .gitignore).. such as the build folder in a java project.

How do I make an adb push command that ignores a certain directory but copies everything else?
This sounds like an XY problem as excluding files and directories with adb push isn't what you're really intending to do.

If you're syncing Git repositories, the best option is a Git client. The one I'm currently using is Termux and I do a lot of development on my phone with it.

Download Termux and use its built-in APT package manager to install Git and you'll be able to process your work easily.