Re: Wolfram Workbench and package development

*To*: mathgroup at smc.vnet.net*Subject*: [mg68448] Re: Wolfram Workbench and package development*From*: "Pratik Desai" <pratikd at wolfram.com>*Date*: Sat, 5 Aug 2006 03:46:51 -0400 (EDT)*References*: <eauv6o$15m$1@smc.vnet.net>*Sender*: owner-wri-mathgroup at wolfram.com

John Jowett wrote: > I've installed and taken a look at Wolfram Workbench (WW). Before deciding > to adopt it for my work, I'd like to raise a few questions concerning how > one might use it for package development. It would be interesting to hear > other people's thoughts. > > 1. WW is clearly an alternative to the traditional workflow for package > development in a notebook (which I learned from Roman Maeders' book > "Programming in Mathematica"). In that scheme, package functions are created > in initialisation cells and the notebook can hold documentation, examples > and so on. I've been doing this for years but somehow never got round to > the next step which is to write additional documentation notebooks for > integration in the Help Browser. Presumably this can be done in WW, > perhaps more efficiently. It may seem fairly obvious but it would be > useful if someone would spell out an authoritative recipe for doing so (and > ideally put it into the help for WW). Which files should you finally > "export" from the project and give to people to install in their > $(User)BaseDirectory Applications folder? I am not sure if you have looked at the help browser, but these topics are well covered there. integration in the Help browser is more of a Mathematica related issue. > 2. Is the above still the right way to put together and provide Help Browser > documentation for application packages, even for future versions of > Mathematica ? > > 3. What about packages that import other packages, contexts and > sub-contexts, etc.? > > 4. When I try to use the Mathematica Import Wizard to bring existing > notebook-generated packages into WW, I tend to end up with a lot of > non-InputForm syntax ("\[Rule], "\!\(", "\<","\[InvisibleSpace]" etc.). It > would be nice to automatically fix/delete these (although perhaps it should > be the Front End's job). > 5. Is it a good or a bad idea to break a single large package over several > .m files in WW? If good, is it just a mattering of putting Get[...] > commands between the BeginPackage and EndPackage ? I am not a developer for Workbench, the idea here is that Workbench essentially creates .m files, so all the techniques and practises that one uses to create packages in Mathematica apply here as well. > 6. In debugging or improving a function from an existing, loaded package, I > often find myself working on a slightly-renamed version that has been copied > to the Global context (this avoids repeatedly re-launching the kernel, > particularly when it takes some time to get to the point where the new > version of the function can be tested). This method is a little messy, > especially when it uses private functions. How would I do this in WW ? If you just save your work in Workbench, this gets automatically updated to your Mathematica session. If you then Run/Debug your file--these changes are automatically reflected Hope this helps Pratik Wolfram Research > > John Jowett