xref: /openbsd-src/usr.bin/file/magdir/lisp (revision 0ee74395949c27152548431c5cb896cb486a0866)
1*0ee74395Schl#	$OpenBSD: lisp,v 1.5 2009/04/24 18:54:34 chl Exp $
2df930be7Sderaadt
3df930be7Sderaadt#------------------------------------------------------------------------------
4df930be7Sderaadt# lisp:  file(1) magic for lisp programs
5df930be7Sderaadt#
6df930be7Sderaadt# various lisp types, from Daniel Quinlan (quinlan@yggdrasil.com)
736c0c0feStedu
8380b5c7dSchl# updated by Joerg Jenderek
9*0ee74395Schl# GRR: This lot is too weak
10*0ee74395Schl#0	string	;;
11380b5c7dSchl# windows INF files often begin with semicolon and use CRLF as line end
12380b5c7dSchl# lisp files are mainly created on unix system with LF as line end
13*0ee74395Schl#>2	search/2048	!\r		Lisp/Scheme program text
14*0ee74395Schl#>2	search/2048	\r		Windows INF file
15380b5c7dSchl
16380b5c7dSchl0	search/256	(if\ 			Lisp/Scheme program text
17380b5c7dSchl0	search/256	(setq\ 			Lisp/Scheme program text
18380b5c7dSchl0	search/256	(defvar\ 		Lisp/Scheme program text
19380b5c7dSchl0	search/256	(defparam\ 		Lisp/Scheme program text
20380b5c7dSchl0	search/256	(defun\  		Lisp/Scheme program text
21380b5c7dSchl0	search/256	(autoload\ 		Lisp/Scheme program text
22380b5c7dSchl0	search/256	(custom-set-variables\ 	Lisp/Scheme program text
2336c0c0feStedu
24df930be7Sderaadt# Emacs 18 - this is always correct, but not very magical.
2536c0c0feStedu0	string	\012(			Emacs v18 byte-compiled Lisp data
26*0ee74395Schl!:mime	application/x-elc
2736c0c0feStedu# Emacs 19+ - ver. recognition added by Ian Springer
28*0ee74395Schl# Also applies to XEmacs 19+ .elc files; could tell them apart with regexs
29*0ee74395Schl# - Chris Chittleborough <cchittleborough@yahoo.com.au>
3036c0c0feStedu0	string	;ELC
31*0ee74395Schl>4	byte	>18
3236c0c0feStedu>4	byte    <32			Emacs/XEmacs v%d byte-compiled Lisp data
33*0ee74395Schl!:mime	application/x-elc
3436c0c0feStedu
3536c0c0feStedu# Files produced by CLISP Common Lisp From: Bruno Haible <haible@ilog.fr>
36*0ee74395Schl0	string	(SYSTEM::VERSION\040'	CLISP byte-compiled Lisp program
37458b3ebdSmillert0	long	0x70768BD2		CLISP memory image data
3836c0c0feStedu0	long	0xD28B7670		CLISP memory image data, other endian
3936c0c0feStedu
4036c0c0feStedu# Files produced by GNU gettext
4136c0c0feStedu0	long	0xDE120495		GNU-format message catalog data
4236c0c0feStedu0	long	0x950412DE		GNU-format message catalog data
4336c0c0feStedu
4436c0c0feStedu#.com and .bin for MIT scheme
4536c0c0feStedu0	string	\372\372\372\372	MIT scheme (library?)
4636c0c0feStedu
4736c0c0feStedu# From: David Allouche <david@allouche.net>
48*0ee74395Schl0	search/1	\<TeXmacs|	TeXmacs document text
49*0ee74395Schl!:mime	text/texmacs
50