"Pegasus (MVP)" <> a écrit dans le message de news:
Os1G9mK%...
>
> "CenturionX" <> wrote in message
> news:54d2e89f-7be0-452e-b10d-...
> On Aug 7, 3:40 am, "Pegasus \(MVP\)" <I....@fly.com.oz> wrote:
>> "CenturionX" <darwinbaldr...@gmail.com> wrote in message
>>
>> news:ce8a58dc-211e-4393-a1b4-...
>>
>> > Hello everybody,
>>
>> > I'm new in this, about the windows scripting.
>>
>> > I was asked to create a script to compress a group of log files in a
>> > specific directory, verify the compressed file is right and then the
>> > directory size.
>>
>> > The script will work in Windows XP and 2000 server.
>> > Any help will be appreciated
>>
>> > Thanks.
>>
>> You could do this:
>> 1. Compress the files.
>> 2. Uncompress then to a different directory.
>> 3. Compare the two file sets.
>>
>> What exactly do you mean with "and then the directory size."?
>
> Sorry,
>
> After that i have to check the folder size where i compressed all the
> files.
>
> But i don't know what commands to use and this PCs doesn't have
> installed winzip. it has to be with the native compress tool.
>
> Thanks.
>
> ===========
>
> Fine. Make it four steps:
> 1. Compress the files.
> 2. Uncompress then to a different directory.
> 3. Compare the two file sets.
> 4. Compare the size of the original folder with that of
> the uncompress folder from Step 2.
>
Hi,
You can you compress and expand from the Ressource Kit and the fc command
from shell. That might be ok.
For the FCcommand, you can use /B for binary, /L for ascii or /U for unicode
SET src=<path\file>
SET dst=<path\file.zip>
SET exp=<path>
COMPRESS -z %src% %dst%
EXPAND %dst% %exp%
FC /B %src% %exp%\file
Regards,
Manu.
|