From: Duncan L. <dli...@gm...> - 2007-07-06 10:04:31
|
On Thu, 2007-07-05 at 18:33 -0700, Alex Roitman wrote: > On Thu, 2007-07-05 at 21:25 -0400, Malcolm Litchfield wrote: > > A great idea, but I'm having trouble executing it. gunzip says that it > > doesn't recognize the suffix and doesn't do anything Why does this happen. I always have this problem! I think I found the solution was simply to add the suffix .gz . So why isn't it the suffix by default. The file is a GRAMPS XML file, compressed. So it would seem to my simple mind reasonable to call it file.gramps.gz (or whatever compression is used). What about it? Duncan |
From: Dave P. <dav...@gm...> - 2007-07-06 10:06:15
|
On 06/07/07, Duncan Lithgow <dli...@gm...> wrote: > by default. The file is a GRAMPS XML file, compressed. So it would seem > to my simple mind reasonable to call it file.gramps.gz (or whatever > compression is used). > > What about it? Yes please. regards -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk |
From: Don A. <don...@co...> - 2007-07-06 11:57:34
|
$ gunzip < file.gramps > file.xml or=20 $ zcat file.gramps > file.xml On Fri, 2007-07-06 at 11:06 +0100, Dave Pawson wrote: > On 06/07/07, Duncan Lithgow <dli...@gm...> wrote: > > by default. The file is a GRAMPS XML file, compressed. So it would seem > > to my simple mind reasonable to call it file.gramps.gz (or whatever > > compression is used). > > > > What about it? >=20 > Yes please. >=20 > regards >=20 >=20 >=20 >=20 |
From: Dave P. <dav...@gm...> - 2007-07-06 12:17:31
|
On 06/07/07, Don Allingham <don...@co...> wrote: > $ gunzip < file.gramps > file.xml [dpawson@marge pres]$ gunzip data.gramps gunzip: data.gramps: unknown suffix -- ignored as we explained. Fedora. > > or > > $ zcat file.gramps > file.xml [dpawson@marge pres]$ zcat data.gramps zcat: data.gramps: not in gzip format Seems it's OS dependent? regards -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk |
From: Don A. <don...@co...> - 2007-07-06 13:00:09
|
You missed the '<' sign $ gunzip < data.gramps > data.xml And if zcat failed, that meant the file was not compressed. GRAMPS cannot use a .gz extension. The .gz extension is associated by the system as type "application/x-gzip". The .gramps extension is associated with "application/x-gramps-xml" GRAMPS opens files of type "application/x-gramps" and "application/x-gramps-xml". It would not recognize the data.gramps.gz file, because the system decides that it is a different type. Also, the system would try to open data.gramps.gz with a tool such as File Roller, instead of GRAMPS. This is similar to OpenOffice files. These files are actually ZIP files, but the have the extension of .odt instead. You can run "unzip" on this file, and it will expand to a collection of XML files. But if it as called ".zip", OpenOffice would not be able to open it. This is just one of those things that has to be the way it is. To access the XML, you will have to manually gunzip the file. $ gunzip < data.gramps > data.xml The ">" and "<" are important. Don On Fri, 2007-07-06 at 13:17 +0100, Dave Pawson wrote: > On 06/07/07, Don Allingham <don...@co...> wrote: > > $ gunzip < file.gramps > file.xml >=20 > [dpawson@marge pres]$ gunzip data.gramps > gunzip: data.gramps: unknown suffix -- ignored >=20 >=20 > as we explained. > Fedora. >=20 >=20 > > > > or > > > > $ zcat file.gramps > file.xml >=20 > [dpawson@marge pres]$ zcat data.gramps > zcat: data.gramps: not in gzip format >=20 >=20 > Seems it's OS dependent? >=20 > regards >=20 |
From: Dave P. <dav...@gm...> - 2007-07-06 13:53:23
|
On 06/07/07, Don Allingham <don...@co...> wrote: > You missed the '<' sign > > $ gunzip < data.gramps > data.xml Boy you take some persuading. [dpawson@marge pres]$ gunzip < data.gramps >x.xml gunzip: stdin: not in gzip format > > And if zcat failed, that meant the file was not compressed. Same difference. > > > GRAMPS cannot use a .gz extension. The .gz extension is associated by > the system *which* 'kin system? > GRAMPS opens files of type "application/x-gramps" over http? > > Also, the system which 'kin system. > > This is similar to OpenOffice files. No it's not. > This is just one of those things that has to be the way it is. On your 'kin system. Now get off yer high horse and rtfm -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk |
From: Piotr C. <pio...@gm...> - 2007-07-06 15:31:52
|
On 7/6/07, Dave Pawson <dav...@gm...> wrote: > > [dpawson@marge pres]$ gunzip < data.gramps >x.xml > > gunzip: stdin: not in gzip format Maybe you've already corrupted the file and it's not gzip any more. This should definitely work. When I want to decompress a GRAMPS file using KDE, I open it with Ark and choose the gzip format. No problems ever occur. > > GRAMPS cannot use a .gz extension. The .gz extension is associated by > > the system > > *which* 'kin system? Every Linux system. .gz is a standard extension that is always opened with default compressed files handler. > > GRAMPS opens files of type "application/x-gramps" > > over http? Locally too. MIME types are defined for files no matter where they're stored. > > This is similar to OpenOffice files. > > No it's not. Yes it's the same, with the only distinctions that OOo uses zip format, and they contain more than just one file. Anyway all files saved by it, regardless of their extension, are actually zipped archives. Piotrek |
From: Don A. <don...@co...> - 2007-07-07 03:51:10
|
On Fri, 2007-07-06 at 14:53 +0100, Dave Pawson wrote: > On 06/07/07, Don Allingham <don...@co...> wrote: > > You missed the '<' sign > > > > $ gunzip < data.gramps > data.xml >=20 > Boy you take some persuading. >=20 > [dpawson@marge pres]$ gunzip < data.gramps >x.xml >=20 > gunzip: stdin: not in gzip format >=20 It looks to me as if this file was not gzip'd. You can check by running the following command: $ file data.gramps My guess is that the file is already uncompressed. If so, the file command will report that it is an XML file. > > GRAMPS cannot use a .gz extension. The .gz extension is associated > by > > the system >=20 > *which* 'kin system? As others have indicated, the system is your computer. Desktop environments such as KDE and GNOME use the Free Desktop's Shared Mime System. Of course, I may be misunderstanding you here. I'm not sure what a 'kin system is. > > GRAMPS opens files of type "application/x-gramps" >=20 > over http? Actually, yes it will. And locally. This is one of the nice things about the shared mime system. The type of file is identified by the shared mime system to your desktop environment, the desktop opens the application associated with the mime type. So if you are downloading from the web or clicking on the file in the file manager, the system handles it the same way. >=20 > > > > This is similar to OpenOffice files. >=20 > No it's not. Actually it is. The ODT format is a zip archive. You can verify it by doing the following: $ unzip test.odt Archive: ../test.odt inflating: mimetype =20 inflating: meta.xml =20 inflating: settings.xml =20 inflating: META-INF/manifest.xml =20 inflating: styles.xml =20 inflating: content.xml =20 And rename an ODT file to eliminate the extension. Then the file will be identified by its contents instead of by its extension. Your file manager will identify it as "application/zip", not as "application/vnd.oasis.opendocument.text" >=20 >=20 > > This is just one of those things that has to be the way it is. >=20 >=20 > On your 'kin system. Again, I'm not sure what a 'kin system is, but this is pretty standard on Linux, BSD, and most other systems. >=20 > Now get off yer high horse and rtfm >=20 Your signature indicates that you are from the UK, so that probably means you don't realize that the above comment is usually considered a bit rude to those of us on the other side of the pond. Especially for someone who is trying to provide help. So, I'm just going to assume that this is just one of those phrases that means something else over there. Alex and I have tried to sum up the XML handling at the following web page: http://www.gramps-project.org/wiki/index.php?title=3DGenerate_XML Don |
From: Alex R. <sh...@gr...> - 2007-07-06 17:14:22
|
On Fri, 2007-07-06 at 14:53 +0100, Dave Pawson wrote: > gunzip: stdin: not in gzip format If it is not in gzip format then there's not much gunzipping you can do. > > And if zcat failed, that meant the file was not compressed. >=20 > Same difference. ? File is either gzipped or not. In former case, you need to gunzip it. In latter you don't. Use "file data.gramps" to know if it is compressed. > > GRAMPS cannot use a .gz extension. The .gz extension is associated by > > the system >=20 > *which* 'kin system? shared mime type system: http://freedesktop.org/wiki/Software/shared-mime-info > > GRAMPS opens files of type "application/x-gramps" >=20 > over http? Over double-clicking in file manager. Could also be over http if you browser knows to call gramps on type "application/x-gramps". The shared mime system gives browser all the chances to do so. > > Also, the system >=20 > which 'kin system. Shared mime. > > This is similar to OpenOffice files. >=20 > No it's not. I think it is, and merely stating the opposite is not an argument. > > This is just one of those things that has to be the way it is. >=20 > On your 'kin system. >=20 > Now get off yer high horse and rtfm David, I think this is plain rude. Either bring the arguments or drop the issue. Alex --=20 Alexander Roitman http://gramps-project.org |
From: Dave P. <dav...@gm...> - 2007-07-06 17:32:54
|
On 06/07/07, Alex Roitman <sh...@gr...> wrote: > David, I think this is plain rude. > Either bring the arguments or drop the issue. Easy. Bye -- Dave Pawson XSLT XSL-FO FAQ. http://www.dpawson.co.uk |
From: Alex R. <sh...@gr...> - 2007-07-06 17:35:01
|
On Fri, 2007-07-06 at 18:32 +0100, Dave Pawson wrote: > On 06/07/07, Alex Roitman <sh...@gr...> wrote: >=20 > > David, I think this is plain rude. > > Either bring the arguments or drop the issue. >=20 > Easy. >=20 > Bye Bye --=20 Alexander Roitman http://gramps-project.org |