File:  [mozdev] / booksync / downloads / booksync2.bat
Revision 1.2: download - view: text, annotated - select for diffs - revision graph
Wed May 21 15:42:26 2003 UTC (14 years, 5 months ago) by simon
Branches: MAIN
CVS tags: HEAD
*** empty log message ***

@echo off
rem S2's bookmark sync
rem this is a very small and easy bat file for windows.
rem it allows you to download your bookmarks from an ftp
rem server for use with mozilla (or any other browser for
rem that matter), and reups them on the server when you
rem close your mozilla session.
rem all you have to do is to edit the variables below, and
rem launch this file instead of mozilla.exe directly.

rem --- editable section ---

rem -+- ftp info -+-

set ftpserver=<your ftp server here>
set ftpuser=<your username here>
set ftppass=<your password here>
set ftpfile=bookmarks.html

rem -+- local file info -+-

set localbookdir=C:\Documents and Settings\S2\Application Data\Mozilla\Profiles\default\upmgqcl8.slt

rem -+- where is mozilla? -+-

set batmozpath=C:\Program Files\\Mozilla\mozilla.exe

rem --- end editable section ---

set batupordown=down

if "%1"=="up" set batupordown=up

copy /y %localbookdir%\bookmarks.html %localbookdir%\bookmarks.html.bk > nul

echo open %ftpserver% > %temp%\boksynctmp
echo %ftpuser%>> %temp%\boksynctmp
echo %ftppass%>> %temp%\boksynctmp
echo type ascii >> %temp%\boksynctmp
if "%batupordown%"=="down" echo get %ftpfile% "%localbookdir%\bookmarks.html" >> %temp%\boksynctmp
if "%batupordown%"=="up" echo send "%localbookdir%\bookmarks.html" %ftpfile% >> %temp%\boksynctmp
echo quit >> %temp%\boksynctmp

ftp -s:%temp%\boksynctmp

del /f /q %temp%\boksynctmp > nul

if "%batupordown%"=="down" %batmozpath% %2 %3 %4 %5 %6 %7 %8 %9
if "%batupordown%"=="down" call %0 up

FreeBSD-CVSweb <>