FireFox Portable(Windows)をUSBメモリで使っているときにブックマークやパスワードを秘密のフォルダにバックアップして使うバッチファイルのソース

Windows Vista用。
FireFox PortableをWindowsで使っていて、ブックマークとサイトパスワードを秘密のフォルダからバックアップして起動&秘密のフォルダにバックアップして終了する.batファイル。
※自己責任でご利用のこと。以下のソースの利用で何らかのトラブルがあっても当方では責任を負いません。
USBメモリをEドライブ、FireFox Portableの「FirefoxPortable.exe」をEドライブの「FireFox Portable」フォルダにおいているとき。
また、秘密のフォルダをEドライブの「himitsu」フォルダとするとき。
なお、秘密のフォルダはUSBメモリをはずす前に、別途セキュリティソフトなどで暗号化しておくこと。

起動版*1

Robocopy E:\himitsu E:\FirefoxPortable\Data\profile bookmarks.html /mov /xo
Robocopy E:\himitsu E:\FirefoxPortable\Data\profile key3.db /mov /xo
Robocopy E:\himitsu E:\FirefoxPortable\Data\profile signons3.txt /mov /xo
cd E:\FirefoxPortable
start "" "FirefoxPortable.exe"
<end>
exit


FireFox終了版。

taskkill /im firefox.exe
Robocopy E:\FirefoxPortable\Data\profile E:\himitsu bookmarks.html /mov /xo
Robocopy E:\FirefoxPortable\Data\profile E:\himitsu key3.db /mov /xo
Robocopy E:\FirefoxPortable\Data\profile E:\himitsu signons3.txt /mov /xo
<end>
exit

*1:2009年6月16日追記:.exeファイルの起動を、直接指定からstartを使って指定するように変更しました。DOS窓が閉じない不具合があったためです。