Re: [racket-users] How to implement a dynamic plugin system?

2017-02-08 Thread Erich Rast
Thanks Matthias and Laurent for your advice! I've taken a look at the source code in MrEd designer and understand how dynamic-require works, but have decided against the plugin structure at least for now, since plugin access to a shared database creates other problems - it turned out at a closer

Re: [racket-users] How to implement a dynamic plugin system?

2017-02-07 Thread Laurent
There's also a plugin system in MrEdDesigner based on the directory structure to load various widgets at runtime: https://github.com/Metaxal/MrEd-Designer/blob/master/mred-designer/plugin.rkt https://github.com/Metaxal/MrEd-Designer/blob/master/mred-designer/mred-plugin.rkt

Re: [racket-users] How to implement a dynamic plugin system?

2017-02-07 Thread Matthias Felleisen
Erich, your needs sound very much like those of DrRacket’s. You may wish to study how DrRacket loads tools (as in take a look at the source) — Matthias > On Feb 7, 2017, at 9:31 AM, Erich Rast wrote: > > Thanks for the advice. So I should use dynamic-require, but how?

Re: [racket-users] How to implement a dynamic plugin system?

2017-02-07 Thread Erich Rast
Thanks for the advice. So I should use dynamic-require, but how? When I tried to use it like "require" it didn't have the desired effect - nothing was imported. I have to admit I'm struggling a bit with all the different ways of load/eval/require/enter code that I've found in the docs so far.

Re: [racket-users] How to implement a dynamic plugin system?

2017-02-07 Thread WarGrey Gyoudmon Ju
I think you can check the source of `raco` which uses the `info.rkt` to search all subcommands(see `racket/getinfo`). In this way, all plugins are just normal packages, you do not have to reside them is a specific directory. Certainly, the plugin is loaded via `dynamic-require`, if the plugin

[racket-users] How to implement a dynamic plugin system?

2017-02-07 Thread Erich Rast
Hi all! I'm thinking about implementing a dynamic plugin system for a large application. Each plugin should have the full racket/gui language and a number of pre-defined imports from modules of the main application available. Plugins should reside in a relative directory and loadable on demand at