Version control local Nas backup

How can I setup a version control that uses my NAS, my NAS is very basic it can’t run linux. I’d like to say run git on my windows and use source tree as a gui. and some how point it at the nas like its main storage. I currently have NAS as letter Z: and I also have a Mac. that I’d like to maybe work on so it could grab the files from the NAS. and when I say return home connect and upload changes. is any of this possible. I do have a raspberry pi running wirelessly for 3d printer. so I don;t know if it an option too or just get a new PI and setup as a server.