Max for live and Git

Robert Clouth's icon

Hey!
I'm still looking for tips on doing serious M4L dev with git.
The issue is that amxds are binary so git can't do proper tracking. I thought about having a shell amxd that's just a bpatcher to the real gittable patch, but that seems ugly.
How do you guys do it?

Rob

Tj Shredder's icon

Develop directly in Max, to make a max patch into an amxd is easy in the end. Max patches are JSON text files.

tyler mazaika's icon

Yes, develop directly in Max. Then you can track your changes to all your different .maxpat files separately, too.

Robert Clouth's icon

Thanks for the tips. But isn't it a bit annoying having to create the amxd every time you want to test it? Especially if you use settings that are built into the amxd like latency compensation. Ideally I'd like to be able to edit in Live. Some kind of automatic build process would be super handy. At the moment it's all a bit clumsy.

Diemo Schwarz's icon

While we all wait for Cycling to do this properly, here is my ridiculously brute force solution to get a human-readable idea of what changed in a patch or amxd in text form, integrated into git: https://github.com/diemoschwarz/diff-for-max

Trevor being Trevor's icon

Is this still the case? When I open my .amxd files with notepad they look very similar to .maxpat files (i.e. not binary as OP mentioned)

allforabit's icon

I'm struggling with getting a good workflow with git or having a device as part of a wider project. It just seems to want to copy the project to the Documents folder all the time. It's really a confusing system. Currently does anyone know of a way to open the device via Live (so that you can see relevant debug info , relating to a currently open Live set) but also just keep the files in the folder that you have saved them in? Thanks for any pointers!

allforabit's icon

The workaround that I found that seems to be doing the trick is to symlink the folder that will be auto created in the Max 8 Documents directory to the original source directory. In Windows this is `mklink /J "C:\Users\<user>\Documents\Max 8\Max for Live Devices\device-name Project" "C:\Users\<user>\Documents\GitHub\project\actual-directory-i-want-files-to-be-in".

Mattijs Kneppers's icon

Hi Allforabit, my reply to this thread might be relevant: https://cycling74.com/forums/bpatcher-keeps-creating-duplicate-files-and-using-old-version. In short Max should never make copies in your Documents folder as long as you don't unfreeze your devices, and I always work on devices in an unfrozen state.

allforabit's icon

Perfect thanks again Mattijs, that has clarified a lot of things for me !