Does iCloud Drive backup hidden dot folders/files such as .git?
I've decided that because I can see the files within my iCloud folder in Finder by unhiding all hidden files, they are also backed up.

Confirmed with colleague that .git folder persists across machines!