With -fdevelopment you get a snap application that watches both the templates and the code for changes and reloads accordingly. Is there a way to get an application that would only reload the templates in case of changes and not the code?
Our use case is this: The person doing templates has a directory containing a snaplet subdirectory and all the needed templates. The snap application is started in this directory. If he changes the templates the application should reload the templates. But we don't need code recompilation. In fact, snap's attempts at code reloading cause trouble, i.e.:
can't find a package database at dist/package.conf.inplace
On Wed, Mar 21, 2012 at 9:01 PM, shahn <soenkeh...@gmail.com> wrote: > Hi!
> With -fdevelopment you get a snap application that watches both the > templates and the code for changes and reloads accordingly. Is there a way > to get an application that would only reload the templates in case of > changes and not the code?
> Our use case is this: The person doing templates has a directory containing > a snaplet subdirectory and all the needed templates. The snap application is > started in this directory. If he changes the templates the application > should reload the templates. But we don't need code recompilation. In fact, > snap's attempts at code reloading cause trouble, i.e.:
> can't find a package database at dist/package.conf.inplace
> On Wed, Mar 21, 2012 at 9:01 PM, shahn <soenkeh...@gmail.com> wrote:
> > Hi!
> > With -fdevelopment you get a snap application that watches both the
> > templates and the code for changes and reloads accordingly. Is there a > way
> > to get an application that would only reload the templates in case of
> > changes and not the code?
> > Our use case is this: The person doing templates has a directory > containing
> > a snaplet subdirectory and all the needed templates. The snap > application is
> > started in this directory. If he changes the templates the application
> > should reload the templates. But we don't need code recompilation. In > fact,
> > snap's attempts at code reloading cause trouble, i.e.:
> > can't find a package database at dist/package.conf.inplace
Note that we restricted this to requests coming from localhost because otherwise there's the potential for a DOS attack. If you want it available from outside the site, you could create your own route for it and control access with auth.
>> On Wed, Mar 21, 2012 at 9:01 PM, shahn <soenkeh...@gmail.com> wrote: >> > Hi!
>> > With -fdevelopment you get a snap application that watches both the >> > templates and the code for changes and reloads accordingly. Is there a >> > way >> > to get an application that would only reload the templates in case of >> > changes and not the code?
>> > Our use case is this: The person doing templates has a directory >> > containing >> > a snaplet subdirectory and all the needed templates. The snap >> > application is >> > started in this directory. If he changes the templates the application >> > should reload the templates. But we don't need code recompilation. In >> > fact, >> > snap's attempts at code reloading cause trouble, i.e.:
>> > can't find a package database at dist/package.conf.inplace
> >> On Wed, Mar 21, 2012 at 9:01 PM, shahn <soenkeh...@gmail.com> wrote:
> >> > Hi!
> >> > With -fdevelopment you get a snap application that watches both the
> >> > templates and the code for changes and reloads accordingly. Is there a
> >> > way
> >> > to get an application that would only reload the templates in case of
> >> > changes and not the code?
> >> > Our use case is this: The person doing templates has a directory
> >> > containing
> >> > a snaplet subdirectory and all the needed templates. The snap
> >> > application is
> >> > started in this directory. If he changes the templates the application
> >> > should reload the templates. But we don't need code recompilation. In
> >> > fact,
> >> > snap's attempts at code reloading cause trouble, i.e.:
> >> > can't find a package database at dist/package.conf.inplace
> >> > Thanks,
> >> > Sönke
Am Donnerstag, 22. März 2012 02:23:17 UTC+1 schrieb mightybyte:
> Note that we restricted this to requests coming from localhost because
> otherwise there's the potential for a DOS attack. If you want it
> available from outside the site, you could create your own route for
> it and control access with auth.
> On Wed, Mar 21, 2012 at 9:17 PM, shahn <soenkeh...@gmail.com> wrote:
> > I see. This does exactly, what we need:
> > while inotifywait snaplets/heist/resources/**/* ; do curl
> > localhost:8000/admin/reload ; done
> > That's great, thanks.
> > Am Donnerstag, 22. März 2012 02:05:09 UTC+1 schrieb mightybyte:
> >> On Wed, Mar 21, 2012 at 9:01 PM, shahn <soenkeh...@gmail.com> wrote:
> >> > Hi!
> >> > With -fdevelopment you get a snap application that watches both the
> >> > templates and the code for changes and reloads accordingly. Is there a
> >> > way
> >> > to get an application that would only reload the templates in case of
> >> > changes and not the code?
> >> > Our use case is this: The person doing templates has a directory
> >> > containing
> >> > a snaplet subdirectory and all the needed templates. The snap
> >> > application is
> >> > started in this directory. If he changes the templates the application
> >> > should reload the templates. But we don't need code recompilation. In
> >> > fact,
> >> > snap's attempts at code reloading cause trouble, i.e.:
> >> > can't find a package database at dist/package.conf.inplace