Parallel Mac and Windows development

Hello to anyone who wandered into this thread. I’m working as an independent developer nowadays. While my long experience has left me well-prepared for many aspects of this change, I’m finding that simple things trip me up once in a while. The big corporation solution is not the same as what a small business would need.

Case in point is sharing a code base between Mac and Windows. In my former life, the company used [color=#0080FF]Perforce[/color] as a code management solution. This gave source code control and also managed the linefeed issue that Mac users experience after their code has gone through a Windows editor. But Perforce is structured for larger companies using a dedicated server on a network (let’s leave out virtual servers for just a minute). My world consists of a Mac Pro stuffed with memory, hard drives and a couple of virtualizers.

I would imagine that many–if not most–of the developers on this forum live in a world that’s not too different from mine. Do you have any favorite ways of dealing with issues of source code control and linefeed sanity? Thanks much for any comments.

For linefeed sanity I wrote myself a quick-and-dirty tool that scans the whole juce tree, replacing any non-standard linefeeds, trimming whitespace from the ends of lines, and warning me if any files contain tab characters. It only takes a second to run, so I always do that before committing anything.

Not sure if this exactly deals with the linefeed issue but I develop mainly on the Mac. When I need to compile my projects for Windows I use a VirtualBox VM and add my home directory as a shared folder. I can then just navigate to the folder on my Mac hard drive from Windows and compile there. Its not as fast as compiling on a native machine but I don’t have to do it all that often and means I only have to keep one copy of my project. I use Git for versioning. is a good service that offers unlimited free private repositories.

Thanks Dave. You’re working pretty much the way I do. I have both VMware and Parallels and prefer to run Windows in a virtual machine (It always feels a little odd when I bring up Win7 under bootcamp). I’ll chalk Git on the leaderboard and see what experiences others have. Jules’s script is a solution we occasionally used at my old company when somebody screwed up, but it’s one I hope to avoid (any backup will see the change when there’s not really a meaningful difference).

If you use Git, line endings are handled automatically if you set the option in your config:

Same here. OSX dev and for windows compilation/testing, I mostly use parallels VM with shared folders.
So 1 code base and git here as well.

PS : VM works great and very fast once using with SSD hard drives


This sounds handy! I would like such a tool