Hey Dario, I have been thinking about this, I saw a tcl/tk plug in to receive the console messages in a patch, continuing down this road I guess you could also save in a text file, all missing dependencies. I don't think it should be much of a problem to write an external that does that.
cheers On Sat, Nov 17, 2018 at 6:51 PM Dario Sanfilippo <[email protected]> wrote: > Thanks, Henri. I'm very grateful for your time. > > Yes, it is helpful :) > > D > > > On Fri, 16 Nov 2018 at 22:57, Henri Augusto Bisognini < > [email protected]> wrote: > >> It really depends on how you managed your dependencies. That seems like >> an easy matter but it is more complicated than it look (and than it should) >> >> I will write down how i do it: >> >> _________________________________________ >> >> *(you probably know that but just for the record: the .pd are text files >> that can be opened in any text editor)* >> >> Most powerful programming text editors (atom/sublime text/etc) can >> perform searches in all files inside a folder. That includes performing >> regex searches. >> _________________________________________ >> >> I've separated the dependencies loading methods but you can of course mix >> all of them. Let's see some possible cases: >> >> *1 - You document your dependencies in a readme file, in your library >> main help patch or in any other sensible way: *take a moment to salute >> yourself for having good programming habits and appreciate the fact that >> you can just read your documentation to see what you need. >> >> If you do that you might skip the rest but it might still be useful when >> dealing with other people's code... >> >> Okay, if you don't do number *1... *first of all: start doing it :) >> >> *2* -*externals are loaded using [declare] :* search the .pd files for >> "declare " so you can easily see what externals you're using >> >> *3* -* externals are loaded using the [library name/external] syntax: * >> search, *using regexp,* the .pd files for .*\/.* >> that finds stuff in the form "some words/some words" >> btw i personally recommend using the PD's auto >> completion plugin for writing code using in that syntax. It avoids name >> clashes and makes it absolutely clear which library you're using and where. >> search for completion-plugin on deken. I'm already >> working on the next version with new features and bugfixes. >> >> *4* -* externals are loaded on startup (that includes using pd >> extended): * well, in that case it will be really hard to know what >> you're using withouth using the trick i will describe below. >> >> _________________________________________ >> >> *Trick:* >> >> let PD tell you whats missing by running vanilla completely stripped down. >> >> How to do that may vary according to your setup but it usually consists >> of: >> >> -Removing all startup flags to load libraries. >> -Removing all search paths >> -removing libraries/externals you've installed in the standar paths >> >> Now when you open a patch PD won't be able to load any externals. So, >> reduced only to vanilla objects, you will get an error message everytime >> something couldn't be loaded. >> >> Then add whats missing, *write it down the dependencies, *and set PD to >> find them again (adding a search path, etc). >> >> *Then repeat until you don't get any errors.* >> >> Repeating is important because those depencies you've just added might >> have their own dependencies. >> >> Let me quickly share one thing i've learned from experience: >> >> If in doubt, paranoid or if you're sending important files, be sure to >> test them in another computer. If you're sending a patch to a performance >> of one of your pieces in a festival for example. Always test in another >> computer just to be sure. And test it on the platform they're going to use. >> >> _________________________________________ >> >> *Tip:* >> >> This is very personal but i like to put all my libraries in a "my >> externals" folder and add only that one folder to the search paths. >> >> Why? >> >> Let's say you add "*C:\Users\YourName\Desktop\Pure Data\libs\cyclone*" >> to your search paths because thats where you've just installed cyclone. >> >> Then you add "*C:\Users\YourName\Desktop\Pure Data\libs\easyflow*" to >> your search paths because thats where you've just installed easyflow. >> >> Then you type [counter] and you don't know if you've loaded the counter >> object from cyclone or from easyflow. >> >> So i add "*C:\Users\YourName\Desktop\Pure Data\libs\*" and then i can >> use [easyflow/counter] and [cyclone/counter] and i know exactly what i'm >> getting. Plus having only 1 search path makes it really easier/quicker to >> use the trick above. >> >> _________________________________________ >> >> Now that you can find your dependencies then, as of current state of >> development, you must include them manually in your zip file. >> >> Hope that helps you or anyone searching through the mailing list. >> >> Cheers, >> Henri. >> >> ------------------------------ >> *De:* Pd-list <[email protected]> em nome de Dario Sanfilippo >> <[email protected]> >> *Enviado:* sexta-feira, 16 de novembro de 2018 16:57 >> *Para:* pd-list >> *Assunto:* [PD] Exporting a patch as a zip file >> >> Hello, list. >> >> Do you have a workaround for exporting a patch as a zip file containing >> all abstractions and externals in the patch? >> >> It would be amazing to be able to do that because manually locating all >> the necessary abstractions and externals from a supposedly large folder is >> a bit tricky and many are often left behind. >> >> Thanks, >> Dario >> > _______________________________________________ > [email protected] mailing list > UNSUBSCRIBE and account-management -> > https://lists.puredata.info/listinfo/pd-list > -- José Rafael Subía Valdez www.jrsv.net
_______________________________________________ [email protected] mailing list UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
