Re: undeterministic zip?

2005-05-14 Thread Noam Meltzer
On Monday 09 May 2005 18:23, Shachar Shemesh wrote:
 Ira Abramov wrote:

 Well, one surpirse. i is not for bzip. If you want bzip, try j.

i was the flag for bzip2 compressing around 4-5 years ago. Then some1 
thought it can be nice to change the flag to j.

-- 
Noam Meltzer

=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]



Re: undeterministic zip?

2005-05-14 Thread Shachar Shemesh
Noam Meltzer wrote:
On Monday 09 May 2005 18:23, Shachar Shemesh wrote:
 

Ira Abramov wrote:
Well, one surpirse. i is not for bzip. If you want bzip, try j.
   

i was the flag for bzip2 compressing around 4-5 years ago. Then some1 
thought it can be nice to change the flag to j.
 

I know that Electronics Engineers are particularily fond of referring to 
i as j. This may be such a case.

 Shachar
--
Shachar Shemesh
Lingnu Open Source Consulting ltd.
Have you backed up today's work? http://www.lingnu.com/backup.html
=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]


Re: undeterministic zip?

2005-05-14 Thread Tzafrir Cohen
On Sat, May 14, 2005 at 11:55:44AM +0300, Noam Meltzer wrote:
 On Monday 09 May 2005 18:23, Shachar Shemesh wrote:
  Ira Abramov wrote:
 
  Well, one surpirse. i is not for bzip. If you want bzip, try j.
 
 i was the flag for bzip2 compressing around 4-5 years ago. Then some1 
 thought it can be nice to change the flag to j.

I actually first encountered it as -y. IIRC those two were rejected due
to conflict with existing flags of other tar commands (Solaris tar?)

-- 
Tzafrir Cohen | [EMAIL PROTECTED] | VIM is
http://tzafrir.org.il |   | a Mutt's  
[EMAIL PROTECTED] |   |  best
ICQ# 16849755 |   | friend

=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]



Re: undeterministic zip?

2005-05-09 Thread Christoph Bugel
Ira Abramov wrote:
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
484497aa0d7e1bb391a73cc8b42acce2  -
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
552bbc02b0b2b5b142a425d476f0d5c0  -
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
792afdaf2be839dfccc1c91dfd4f726b  -
what the fsck is going on?! is gzip adding some odd time stamp or
something?!
Indeed. Seems to be fixed with gzip -n
$ tar cf - directory | gzip -n | md5sum
59d0f9e8ae05efbd55039010c3461878 *-
[EMAIL PROTECTED] ~
$ tar cf - directory | gzip -n | md5sum
59d0f9e8ae05efbd55039010c3461878 *-
[EMAIL PROTECTED] ~
$ tar cf - directory | gzip -n | md5sum
59d0f9e8ae05efbd55039010c3461878 *-
(sorry for the w2k thingy)
=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]


Re: undeterministic zip?

2005-05-09 Thread Shachar Shemesh
Ira Abramov wrote:
[EMAIL PROTECTED] ~]$ tar icf - directory |md5sum
03ad652d93447a92eb944cd6acae0471  -
[EMAIL PROTECTED] ~]$ tar icf - directory |md5sum
03ad652d93447a92eb944cd6acae0471  -
[EMAIL PROTECTED] ~]$ tar icf - directory |md5sum
03ad652d93447a92eb944cd6acae0471  -
i for bzip2. still no surprise.
 

Well, one surpirse. i is not for bzip. If you want bzip, try j.
however:
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
484497aa0d7e1bb391a73cc8b42acce2  -
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
552bbc02b0b2b5b142a425d476f0d5c0  -
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
792afdaf2be839dfccc1c91dfd4f726b  -
what the fsck is going on?! is gzip adding some odd time stamp or
something?!
 

It appears so, yes:
ftp://ftp.isi.edu/in-notes/rfc1952.txt
MTIME (Modification TIME)
   This gives the most recent modification time of the original
   file being compressed.  The time is in Unix format, i.e.,
   seconds since 00:00:00 GMT, Jan.  1, 1970.  (Note that this
   may cause problems for MS-DOS and other systems that use
   local rather than Universal time.)  If the compressed data
   did not come from a file, MTIME is set to the time at which
   compression started.  MTIME = 0 means no time stamp is
   available.
--
Shachar Shemesh
Lingnu Open Source Consulting ltd.
Have you backed up today's work? http://www.lingnu.com/backup.html
=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]


Re: undeterministic zip?

2005-05-09 Thread Nadav Har'El
On Mon, May 09, 2005, Christoph Bugel wrote about Re: undeterministic zip?:
 what the fsck is going on?! is gzip adding some odd time stamp or
 something?!
 
 Indeed. Seems to be fixed with gzip -n

Exactly. Read RFC 1952 (http://www.faqs.org/rfcs/rfc1952.html) if you want
to learn more about gzip's format. Specifically,

... If the compressed data did not come from a file, MTIME is set
 to the time at which compression started.  MTIME = 0 means no time
 stamp is available.

-n indeed assures that the time stamp (and name) isn't saved.

-- 
Nadav Har'El| Monday, May 9 2005, 1 Iyyar 5765
[EMAIL PROTECTED] |-
Phone +972-523-790466, ICQ 13349191 |The fact that no one understands you
http://nadav.harel.org.il   |doesn't mean you're an artist.

=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]



Re: undeterministic zip?

2005-05-09 Thread Peter
On Mon, 9 May 2005, Ira Abramov wrote:
however:
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
484497aa0d7e1bb391a73cc8b42acce2  -
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
552bbc02b0b2b5b142a425d476f0d5c0  -
[EMAIL PROTECTED] ~]$ tar zcf - directory |md5sum
792afdaf2be839dfccc1c91dfd4f726b  -
gzip stores the date  time of the uncompressed file, which is made at a 
different time by tar, for each run. man gzip options -l  --verbose.

bzip2 does not store such a date anywhere, thus it is not affected.
Peter
=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]


Re: undeterministic zip?

2005-05-09 Thread Yedidyah Bar-David
Hi all,

This isn't more on topic than the original subject, but I allow myself
to share this very valuable information. From the NEWS file of GNU tar
version 1.15 (which isn't in Debian unstable yet, I do not even remember
how come I ran into this):
version 1.15 - Sergey Poznyakoff, 2004-12-20

* Compressed archives are recognised automatically, it is no longer
necessary to specify -Z, -z, or -j options to read them. Thus, you can
now run `tar tf archive.tar.gz'.

:-)

It's irrelevant for Ira's question, as tar can't guess if you want to
compress an archive. But now it knows to decompress it. If it had this
option a few years ago, it would sure have saved me a few tens of times
re-running tar commands with j and z replaced. But of course I prefferd
to suffer than to think a bit and write such a patch myself (or even
a wrapper script).
-- 
Didi


=
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word unsubscribe in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]