[File] [PATCH] of Magdir/gimp for GIMP animated brush+ extensions +mime types

Christos Zoulas christos at zoulas.com
Tue Oct 15 18:19:58 UTC 2019


On Oct 13,  2:33pm, joerg.jen.der.ek at gmx.net (=?UTF-8?Q?J=c3=b6rg_Jenderek?=) wrote:
-- Subject: [File] [PATCH] of Magdir/gimp for GIMP animated brush+ extensions

| Hello,
| some days ago i handled some files with pat extension. Some belongs to
| graphic software gimp. When i run file command version 5.37 on GIMP
| related samples with -k -m Magdir/gimp options i get an output like:
| 
| 5x5squareBlur.gbr:        GIMP brush data
| Android-icon-palette.gpl: GIMP palette data, ASCII text
| BrushPipe.xcf:            GIMP XCF image data, version 0,
| 			  40 x 40, Greyscale
| elsamuko-autumn:          GIMP curve file
| FILSD_Brush_3.gih:        data
| German_flag_smooth.ggr:   GIMP gradient data, ASCII text
| gimp_platinum.txt:        GIMP curve file
| walnut.pat:               GIMP pattern data, Walnut
| 
| First GIMP animated brush which have gih file name extension are not
| recognised.
| Second only XCF images are shown with a specific mime type when
| using -i option. For text based file types text/plain is shown and
| for all others application/octet-stream is displayed.
| Furthermore with --extension option only ??? is displayed.
| 
| Some global information can be found on gimp online help. Info about
| file format can be found on fileformats.archiveteam.org site. So i
| add comment lines like:
| # URL:	https://docs.gimp.org/en/gimp-using-animated-brushes.html
| # http://fileformats.archiveteam.org/wiki/GIMP_Animated_Brush
| 
| According to above mentioned site and observed examples i look for
| number of cells information by line:
|  0	search/21/b	\040ncells:	GIMP animated brush data
| Afterward user defined mime type and file name extension are shown
| by lines
|  !:mime	image/x-gimp-gih
|  !:ext	gih
| 
| On fileformats website there information of other GIMP formats is
| listed under keyword XCF. So i add listed sub pages URL and file
| name extensions for the other formats like GIMP brushes and so on to
| Magdir/gimp. The information about mime types are found on
| reposcope.com web site.
| 
| After applying the above mentioned modifications by patch
| file-5.37-gimp.diff then i get a more precise output. And with -i
| option now specific mime types are shown like:
| 
| 5x5squareBlur.gbr:        image/x-gimp-gbr; charset=3Dbinary
| Android-icon-palette.gpl: text/x-gimp-gpl; charset=3Dus-ascii
| BrushPipe.xcf:            image/x-xcf; charset=3Dbinary
| elsamuko-autumn:          text/x-gimp-curve; charset=3Dus-ascii
| FILSD_Brush_3.gih:        image/x-gimp-gih; charset=3Dbinary
| German_flag_smooth.ggr:   text/x-gimp-ggr; charset=3Dus-ascii
| gimp_platinum.txt:        text/x-gimp-curve; charset=3Dus-ascii
| walnut.pat:               image/x-gimp-pat; charset=3Dbinary
| 
| I hope my diff file can be applied in future version of
| file utility.
| For the GIMP curves there seems to exist an other file format not
| described on mentioned document sites. This is not recognised by
| file command.

Applied, many thanks!

christos


More information about the File mailing list