Forums > MaxMSP

Find and Replace

Apr 30 2011 | 6:39 pm

So I’m working on a really big patch which contains many different abstractions I have built to assist in reducing the amount of editing time. I’ve recently been working on an update and have found that I need to change most of my abstractions, BUT I want to keep the previous abstractions.

Granted I could save them with a prefix (ie: MyAbstraction becomes OldMyAbstraction). But I want to keep the integrity of the older patch. So I find myself replacing 48 abstractions with different arguments 5 or 6 times. Its exhausting.

I was wondering Cycling74′ folks, could you guys work on a "find and replace" feature? It would be amazing and cut down on mindless programming and let the programmer focus on the important things in life.


Apr 30 2011 | 7:12 pm

bitchslap me if that does not work on max 5, but on max 4 the common way
how to archive this (replace dozens of abstractions or objects) was to save
AS TEXT and then use bbedit or similar text-programs to replace the string
"abstraction" with "abstarctions2".

on my mac os 9 computer this takes abput 3-4 seconds and the change is done.


Apr 30 2011 | 8:44 pm

Max5 patcher are text files, specifically .json files. You may need to do something to convince your text editor that filename.maxpat is a file it can open, but you can probably figure out the .json formatting once that’s done.

Apr 30 2011 | 9:31 pm

I do this all the time with Textedit. I just make sure that the number of inputs and outputs remains consistent and that there are no unpleasant surprises.

For example when if I needed to add an attribute to 52 jit.qt.movies I just look for all instances of 320 240 and find and replace that text with 320 240 @unique 1.

Apr 30 2011 | 10:45 pm

I use TextWrangler for this all of the time. It has a good find/replace across multiple documents.


Viewing 5 posts - 1 through 5 (of 5 total)

Forums > MaxMSP