git subtree push

C++
git subtree push --prefix=my/folder subtree_origin master
Source

Also in C++: