I love FFP! Absolutely awesome.
Anyway..
I moved my cache off the flash and onto
c:\Temp\FFP_Cache
and created a BAT file FFP_Cleanup.bat that contains:
RD /S /Q C:\Temp\FFP_Cache
How can I incorporate this to file to fire automatically when FFP exits?
Thanks,
mc
Short answer: You can't.
Long answer: There's no callback within the launcher to do it, so you can't use that. However, you could execute the launcher within your .bat and have it wait...
"If you're not part of the solution, you're part of the precipitate."
How hard would it be to add that to the launcher (since source code is available)? Would that be very tricky?
MC
I'd say just
Exec
orExecWait
would do it, and is pretty easy to add."If you're not part of the solution, you're part of the precipitate."
Will look into that.
Well... I'm learning... I think...
What I've found out so far. (correct me if I'm wrong)
The FirefoxPortable.exe was created from FirefoxPortable.nsi using NSIS.
NSIS should be able to create and new EXE... but, for me, crashes every time on line 67 due to it not being able to find the Registry.nsh referenced in the NSI file.
What I'm trying to do now is let FFP create the Folder for the cache in the docs&settings and let FFP erase it when finished.
Now I need to create something similar to this attempted mod:
RemoveLocalFiles2:
Delete "$APPDATA\Mozilla\Firefox\pluginreg.dat"
RMDir /R "$APPDATA\Mozilla\Firefox\Cache"
RMDir "$APPDATA\Mozilla\Firefox\" ;=== Will only delete if empty (no /r switch)
RMDir "$APPDATA\Mozilla\" ;=== Will only delete if empty (no /r switch)
StrCmp $MOZILLAORGKEYEXISTS "true" TheEnd
${registry::DeleteKey} "HKEY_CURRENT_USER\Software\mozilla.org" $R0
TheEnd:
${registry::Unload}
newadvsplash::wait
SectionEnd
or
RemoveLocalFiles2:
RMDir /R "$APPDATA\Mozilla\Firefox\"
RMDir "$APPDATA\Mozilla\" ;=== Will only delete if empty (no /r switch)
StrCmp $MOZILLAORGKEYEXISTS "true" TheEnd
${registry::DeleteKey} "HKEY_CURRENT_USER\Software\mozilla.org" $R0
TheEnd:
${registry::Unload}
newadvsplash::wait
SectionEnd
that may not work to well with the new newadvsplash
aslo all you have to do is get the registry header into the header files...i think
Please search before posting. ~Thanks
The first few times you try to run NSIS you'll get errors for plugins that are missing (go to the NSIS site and download them) or graphic/icon files not found (make or grab one and stick it in the designated place) or header files not found (make sure they are where they're supposed to be). Once you get all the missing pieces it should work okay.
SmithTech has some pointers and a package containing most of what you need, but it's not hard to put it together yourself.
MC
What about another file.bat within this?
@echo off
cls
start /wait FirefoxPortable.exe
RD /S /Q C:\Temp\FFP_Cache
EDIT: Oh sorry... I forgot that the launcher not stay open while firefox is closing =[ It'll not work...