My .gitignore contains the following line
build/
And, the directory structure of my project looks like
/myproject
.gitignore
/sub_prj1
/build
/sub_prj2
/build
...
However after git push, the build directory under all sub_prj1, sub_prj2... exists in the remote.
How can I ignore build directory ?