Re: Updating a JavaScript module (jsm)
Arivald <arivald_@AT_interia_DOT_pl.mozilla.org>
| Newsgroups | gmane.comp.mozilla.devel.xpfe |
|---|---|
| Message-ID | <[email protected]> |
W dniu 2011-08-23 21:40, Michael Hofer pisze:
> Am 23.08.11 21:30, schrieb Michael Hofer:
>> I can't effectively update my JSM modules anymore. I'm importing the
>> modules with
>>
>> Components.utils.import("resource://...")
>>
>> from different places in my code (from xbl or regular js files). But the
>> modules seem to be cached somewhere in between restarts of xulrunner
>> (Where?).
> [...]
>
> Update after some fiddling:
>
> *Some* changes in the JSM seem to trigger discarding the cache (maybe
> changing symbol names of EXPORTED_SYMBOLS?). Starting the application
> indirectly via full path to application.ini (-> no menus/dock icon) also
> seems to trigger a reload (sometimes?). Can't say for sure - the caching
> problem appears to happen somewhat inconsistent now.
>
> This makes development a real pain. Where is the JSM code actually
> cached? Maybe there's some file I can delete before application startup?
Are You sure that application do restart?
MacOSX can just hide app in dock (kill all windows and menus, but keep
it loaded to memory). Such app is specifically marked in dock. For FF
and TB, to fully restart app You must select "Quit" from menu, not just
close all windows.
Or You may use console, and use "killall" command to kill process.
http://developer.apple.com/library/mac/#documentation/Darwin/Reference/ManPages/man1/killall.1.html
--
Arivlad