[Grok-dev] Grokker to remove development code?
Sebastian Ware
sebastian at urbantalk.se
Wed Dec 3 04:03:50 EST 2008
Actually, I wanted to mark classes as "development code" so it gets
automatically discarded when running the project on a production server.
I am guessing that with this solution I would have to add the code
manually during deployment.
Mvh Sebastian
2 dec 2008 kl. 17.43 skrev Sylvain Viollon:
> On Tue, 2 Dec 2008 16:02:41 +0100
> Sebastian Ware <sebastian at urbantalk.se> wrote:
>
> Hello,
>
>> I often have the odd class here and there that is mainly intended
>> for development purposes. It would be great if I could mark them
>> somehow in order to exclude them from being registered on the
>> production server.
>>
>> Could this be easily achieved with a custom grokker?
>>
>> Is there any other best practice for this use case?
>
> You can use:
>
> grok.baseclass()
>
> And your code won't be grokked. I would do it like this. If you don't
> like the name, can still do:
>
> developmentcode = grok.baseclass
>
> :)
>
> Sylvain,
>
> --
> Sylvain Viollon -- Infrae
> t +31 10 243 7051 -- http://infrae.com
> Hoevestraat 10 3033GC Rotterdam -- The Netherlands
More information about the Grok-dev
mailing list