How can i set auto reload on a directory?

90 views
Skip to first unread message

Mike Nelson

unread,
Aug 13, 2013, 9:54:16 PM8/13/13
to tincr-for-ch...@googlegroups.com
Hi, I think this is a pretty simple one.

How can I make a json config file to reload the browser (full refresh) when any files in a particular directory are changed (within my editor).

Projects are virtual directories off localhost eg localhost/project1/ localhost/project2/ etc

These do not map exactly to physical directories so I'm thinking I need to set up a tincr.json file containing each virtual directory and corresponding physical directory. Files do not map to URLs (eg I can modify a controller or a view or other files) so I just want any file in the given folder to reload the browser if the browser is on any page on localhost.

Thanks
-Mike

Alex Giannis

unread,
Aug 15, 2013, 5:40:09 PM8/15/13
to tincr-for-ch...@googlegroups.com
To my knowlegde you can't do this with json config.

One workarround for this is to set project1.localhost/ , project2.localhost/  and then specify different root directory for different projects.

Mike Nelson

unread,
Aug 15, 2013, 6:21:04 PM8/15/13
to tincr-for-ch...@googlegroups.com
Thanks. OK, so how do I just simply say any file changed should autoreload any page? Like if I modify a view anywhere under the root folder, it will autoreload the browser if I am anywhere on localhost. 

Is that possible? Otherwise that would mean you would need to repeat all your routing configuration in the tincr.json file?

Cheers
-Mike
Reply all
Reply to author
Forward
0 new messages