|
Joined: Oct 2003
Posts: 11
Pikka bird
|
OP
Pikka bird
Joined: Oct 2003
Posts: 11 |
I was just thinking about reinstalling Windows, and at the same time, I was opening up mIRC. I would like to see a feature that will let you save all yor current settings (fonts, colors, etc.) onto one file, be able to uninstall mIRC, then later, load your settings up just as it was before.
Or possibly just copy all the files's that are needed onto a directory specified (C:\Window\Desktop\mIRC_backup), so you can just overwrite the default settings that are first set when mIRC is first installed.
Yes, I relize you can do it manually, but, an option to do this would be a great addition to mIRC.
Thanks for your time.
|
|
|
|
Joined: Jan 2003
Posts: 3,012
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 3,012 |
1. Insert floppy into Drive A: (Floppy Drive) 2. Type the following in mirc: //run copy $shortfn($mircdirmirc.ini) A: 3. mIRC is now backed up
-KingTomato
|
|
|
|
Joined: Dec 2002
Posts: 3,138
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 3,138 |
Might be better to use $mircini.
|
|
|
|
Joined: Jan 2003
Posts: 3,012
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 3,012 |
I suppose, just that 99% of people use the defualt ini. It would also make for shorter coding >:D
-KingTomato
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
//run copy? Maybe //copy -o $nopath($mircini) A: also perform.ini, control.ini etc..
|
|
|
|
Joined: Oct 2003
Posts: 11
Pikka bird
|
OP
Pikka bird
Joined: Oct 2003
Posts: 11 |
Yeah, thanks... by the time I'd type that all up, I could of manually backup it up (yes, copy/paste). But, this won't back up all my ignores, alias', and whatnot, correct? I figure making a script would be easy for some to make, but yet, the option still would be nice to have, as a default.
|
|
|
|
Joined: Jan 2003
Posts: 3,012
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 3,012 |
in that case...
alias backup { /run cmd /c xcopy $shortfn($mircdir) $+ \*.* A: /EXCLUDE:mirc.exe }
-KingTomato
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
/exclude:file.ext file.ext is a file (or files) containing strings to exclude, not a specific file to exclude. So it would be something like alias backup {
write -c exclude.txt exclude.txt
write exclude.txt .exe
write exclude.txt .hlp
write exclude.txt .gid
write exclude.txt logs\
write exclude.txt download\
; add any other files, extensions or folders to exclude here with the above format.
run cmd.exe /c xcopy * A:\ /Exclude:exclude.txt /E /D
} Edit: Or you could use FOR and COPY, though it won't save the files to their respective directories - //run cmd.exe /c for /r $+(",$mircdir,") % $+ I in (*.ini;*.mrc) do copy "%I" A:
Last edited by Iori; 07/11/03 11:37 AM.
|
|
|
|
Joined: Aug 2003
Posts: 325
Fjord artisan
|
Fjord artisan
Joined: Aug 2003
Posts: 325 |
If using XP: Right click on mirc folder, Send To -> Compressed Folder If not, then download WinZip or WinRAR, etc, and use that. Quick and easy.
|
|
|
|
Joined: Jan 2003
Posts: 2,523
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 2,523 |
Just a minor detail, it might be better to use $logdir and $getdir instead of hardcoding logs\ and download\.
Personally I use Winrar for backups, it has tons of command-line switches that can do virtually anything you want and, of course, compresses files, which is handy if you're saving to a floppy.
/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
Well, that was just a correction of syntax. $logdir,$getdir might be better. I doubt many people would change those to another foldername and still keep them within the $mircdir tree, but it is possible I guess. Personally, I don't have a floppy drive so I don't need to worry about compression.
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
Well, as i stated above, I posted only for corrections of syntax. If the OP doesn't want to use copy\paste I doubt that using sendto would be much different.
|
|
|
|
Joined: Jan 2003
Posts: 2,523
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 2,523 |
Well, that was just a correction of syntax.Yep, I realise that, I replied mostly for fackue and/or others who may find this useful (I know you know these things)
/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
Thought about the compression aspect and made one using makecab (so it is For Win NT only). alias bakup {
if $isfile(bakup.ddf) { .remove bakup.ddf }
.fopen -n bak bakup.ddf
.fwrite -n bak .OPTION EXPLICIT
.fwrite -n bak .Set $+(CabinetName1=Bakup,$date(yymmdd),.cab)
.fwrite -n bak .set DiskDirectoryTemplate=A:\
.fwrite -n bak .Set Cabinet=ON
.fwrite -n bak .Set Compress=ON
.echo -q $findfile($mircdir,*.*,0,if ($istok([color:blue]ini mrc[/color],$gettok($1-,-1,46),32)) $&
.fwrite -n bak $+(",$1-,") $+(",$remove($1-,$mircdir),"))
.comopen %a WScript.Shell
if !$comerr { .comclose %a $com(%a,Run,3,bstr,cmd.exe /c makecab /f bakup.ddf /l A:\,uint,0,bool,true) }
.remove bakup.ddf
.remove setup.inf
.remove setup.rpt
} ini mrc more file ext's can be addedReally it was just a fun waste of time, but someone may find it useful
Last edited by Iori; 08/11/03 10:19 PM.
|
|
|
|
Joined: Jan 2003
Posts: 2,523
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 2,523 |
Very interesting, and very nicely coded I didn't know about makecab, it's a good alternative, since it's free and perhaps more universal (I guess there are more XP users than winrar users). Oh and just my usual pickiness, you can replace if $isfile(bakup.ddf) { .remove bakup.ddf }
.fopen -n bak bakup.ddf with .fopen -n[color:red]o[/color] bak bakup.ddf
/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
Good point with the /fopen -no. Thanks I also see I somehow lost the /fclose line :tongue: So here it is again with the changes. alias bakup {
.fopen -no bak bakup.ddf
.fwrite -n bak .OPTION EXPLICIT
.fwrite -n bak .Set $+(CabinetName1=Bakup,$date(yymmdd),.cab)
.fwrite -n bak .Set DiskDirectoryTemplate=[color:red]A:\[/color]
.fwrite -n bak .Set Cabinet=ON
.fwrite -n bak .Set Compress=ON
.echo -q $findfile($mircdir,*.*,0,if ($istok([color:blue]ini mrc[/color],$gettok($1-,-1,46),32)) $&
.fwrite -n bak $+(",$1-,") $+(",$remove($1-,$mircdir),"))
.fclose bak
var %a = $ticks
.comopen %a WScript.Shell
if !$comerr { .comclose %a $com(%a,Run,3,bstr,cmd.exe /c makecab /f bakup.ddf /l [color:red]A:\[/color],uint,0,bool,true) }
.remove bakup.ddf
.remove setup.inf
.remove setup.rpt
} The two instances of " A:\" can be changed to whatever path, without spaces, you want the cab to go to. Along with a little info on the compression ratio. MakeCAB Report: Sun Nov 09 16:41:32 2003
Total files: 976
^^ (976 files were mostly all copies of each other :D) ^^
Bytes before: 5,093,733
Bytes after: 1,407,097
After/Before: 27.62% compression
Time: 2.84 seconds ( 0 hr 0 min 2.84 sec)
^^ Note this was to a USB external drive ^^ (no floppy drive here to test on)
Throughput: 1749.07 Kb/second
|
|
|
|
|