Thursday, September 6, 2007

Making Pidgin "portable" just got easier.

Here I made a nice little series of commands to drop in a batch file. The only thing I didn't do was add in a line for importing your .purple folder into the \programs folder. But you can do that with :: Xcopy "%appdata%\.purple\*.*" "\programs\.purple\"
Just add it @ the end of your batch file.

::First things first. I'm in UR Echo, dumping my excludes.
Echo \perlmod\ >Exclude1
Echo \locale\ >Exclude2
Echo pidgin-uninst.exe >Exclude3
mkdir Programs
::base dirs
MKDIR Programs\Pidgin\
MKDIR Programs\GTK\
::Pidgin Lines
MKDIR Programs\Pidgin\sounds\
MKDIR Programs\Pidgin\pixmaps\
:: Went with XCOPY instead :p
XCOPY "C:\Program Files\Pidgin\*.*" "Programs\Pidgin\" /E /H /G /EXCLUDE:Exclude1+Exclude2+Exclude3
DEL Programs\Pidgin\plugins\perl.dll
DEL Programs\Pidgin\plugins\tcl.dll
REN Programs\Pidgin\Pidgin.exe Pidgin-portable.exe
:: /Pidgin lines

:: GTK lines "C:\Program Files\Common Files\GTK\2.0"
MKDIR Programs\GTK\
MKDIR Programs\GTK\bin\
MKDIR Programs\GTK\etc\
MKDIR Programs\GTK\lib\
MKDIR Programs\GTK\share\
XCOPY "C:\Program Files\Common Files\GTK\2.0\bin\*.*" "Programs\GTK\bin\" /E /H /G
XCOPY "C:\Program Files\Common Files\GTK\2.0\etc\*.*" "Programs\GTK\etc\" /E /H /G
XCOPY "C:\Program Files\Common Files\GTK\2.0\lib\*.*" "Programs\GTK\lib\" /E /H /G /EXCLUDE:Exclude2
XCOPY "C:\Program Files\Common Files\GTK\2.0\share\*.*" "Programs\GTK\share\" /E /H /G
::/GTK lines
Del Exclude1
Del Exclude2
Del Exclude3

Enjoy.