xref: /freebsd/contrib/file/magic/Magdir/commands (revision 2726a7014867ad7224d09b66836c5d385f0350f4)
1b6cee71dSXin LI
2b6cee71dSXin LI#------------------------------------------------------------------------------
3*2726a701SXin LI# $File: commands,v 1.63 2020/06/06 15:36:30 christos Exp $
4b6cee71dSXin LI# commands:  file(1) magic for various shells and interpreters
5b6cee71dSXin LI#
6b6cee71dSXin LI#0	string/w	:			shell archive or script for antique kernel text
7b6cee71dSXin LI0	string/wt	#!\ /bin/sh		POSIX shell script text executable
8b6cee71dSXin LI!:mime	text/x-shellscript
9b6cee71dSXin LI0	string/wb	#!\ /bin/sh		POSIX shell script executable (binary data)
10b6cee71dSXin LI!:mime	text/x-shellscript
11b6cee71dSXin LI
12b6cee71dSXin LI0	string/wt	#!\ /bin/csh		C shell script text executable
13b6cee71dSXin LI!:mime	text/x-shellscript
14b6cee71dSXin LI
15b6cee71dSXin LI# korn shell magic, sent by George Wu, gwu@clyde.att.com
16b6cee71dSXin LI0	string/wt	#!\ /bin/ksh		Korn shell script text executable
17b6cee71dSXin LI!:mime	text/x-shellscript
18b6cee71dSXin LI0	string/wb	#!\ /bin/ksh		Korn shell script executable (binary data)
19b6cee71dSXin LI!:mime	text/x-shellscript
20b6cee71dSXin LI
21b6cee71dSXin LI0	string/wt 	#!\ /bin/tcsh		Tenex C shell script text executable
22b6cee71dSXin LI!:mime	text/x-shellscript
23b6cee71dSXin LI0	string/wt	#!\ /usr/bin/tcsh	Tenex C shell script text executable
24b6cee71dSXin LI!:mime	text/x-shellscript
25b6cee71dSXin LI0	string/wt 	#!\ /usr/local/tcsh	Tenex C shell script text executable
26b6cee71dSXin LI!:mime	text/x-shellscript
27b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/tcsh	Tenex C shell script text executable
28b6cee71dSXin LI!:mime	text/x-shellscript
29b6cee71dSXin LI
30b6cee71dSXin LI#
31b6cee71dSXin LI# zsh/ash/ae/nawk/gawk magic from cameron@cs.unsw.oz.au (Cameron Simpson)
32b6cee71dSXin LI0	string/wt	#!\ /bin/zsh		Paul Falstad's zsh script text executable
33b6cee71dSXin LI!:mime	text/x-shellscript
34b6cee71dSXin LI0	string/wt	#!\ /usr/bin/zsh	Paul Falstad's zsh script text executable
35b6cee71dSXin LI!:mime	text/x-shellscript
36b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/zsh	Paul Falstad's zsh script text executable
37b6cee71dSXin LI!:mime	text/x-shellscript
38d38c30c0SXin LI0	search/1	#!/usr/bin/env\ zsh	Paul Falstad's zsh script text executable
39d38c30c0SXin LI!:mime	text/x-shellscript
40d38c30c0SXin LI
41b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/ash	Neil Brown's ash script text executable
42b6cee71dSXin LI!:mime	text/x-shellscript
43b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/ae	Neil Brown's ae script text executable
44b6cee71dSXin LI!:mime	text/x-shellscript
45b6cee71dSXin LI0	string/wt	#!\ /bin/nawk		new awk script text executable
46b6cee71dSXin LI!:mime	text/x-nawk
47b6cee71dSXin LI0	string/wt	#!\ /usr/bin/nawk	new awk script text executable
48b6cee71dSXin LI!:mime	text/x-nawk
49b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/nawk	new awk script text executable
50b6cee71dSXin LI!:mime	text/x-nawk
51b6cee71dSXin LI0	string/wt	#!\ /bin/gawk		GNU awk script text executable
52b6cee71dSXin LI!:mime	text/x-gawk
53b6cee71dSXin LI0	string/wt	#!\ /usr/bin/gawk	GNU awk script text executable
54b6cee71dSXin LI!:mime	text/x-gawk
55b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/gawk	GNU awk script text executable
56b6cee71dSXin LI!:mime	text/x-gawk
57b6cee71dSXin LI#
58b6cee71dSXin LI0	string/wt	#!\ /bin/awk		awk script text executable
59b6cee71dSXin LI!:mime	text/x-awk
60b6cee71dSXin LI0	string/wt	#!\ /usr/bin/awk	awk script text executable
61b6cee71dSXin LI!:mime	text/x-awk
6240427ccaSGordon Tetlow0	regex/4096	=^[\040\t\f\r\n]{0,100}BEGIN[\040\t\f\r\n]{0,100}[{]	awk or perl script text
63b6cee71dSXin LI
64b6cee71dSXin LI# AT&T Bell Labs' Plan 9 shell
65b6cee71dSXin LI0	string/wt	#!\ /bin/rc	Plan 9 rc shell script text executable
66b6cee71dSXin LI
67b6cee71dSXin LI# bash shell magic, from Peter Tobias (tobias@server.et-inf.fho-emden.de)
68b6cee71dSXin LI0	string/wt	#!\ /bin/bash	Bourne-Again shell script text executable
69b6cee71dSXin LI!:mime	text/x-shellscript
70b6cee71dSXin LI0	string/wb	#!\ /bin/bash	Bourne-Again shell script executable (binary data)
71b6cee71dSXin LI!:mime	text/x-shellscript
72b6cee71dSXin LI0	string/wt	#!\ /usr/bin/bash	Bourne-Again shell script text executable
73b6cee71dSXin LI!:mime	text/x-shellscript
74b6cee71dSXin LI0	string/wb	#!\ /usr/bin/bash	Bourne-Again shell script executable (binary data)
75b6cee71dSXin LI!:mime	text/x-shellscript
76b6cee71dSXin LI0	string/wt	#!\ /usr/local/bash	Bourne-Again shell script text executable
77b6cee71dSXin LI!:mime	text/x-shellscript
78b6cee71dSXin LI0	string/wb	#!\ /usr/local/bash	Bourne-Again shell script executable (binary data)
79b6cee71dSXin LI!:mime	text/x-shellscript
80b6cee71dSXin LI0	string/wt	#!\ /usr/local/bin/bash	Bourne-Again shell script text executable
81b6cee71dSXin LI!:mime	text/x-shellscript
82b6cee71dSXin LI0	string/wb	#!\ /usr/local/bin/bash	Bourne-Again shell script executable (binary data)
83b6cee71dSXin LI!:mime	text/x-shellscript
845f0216bdSXin LI0	string/wt	#!\ /usr/bin/env\ bash	Bourne-Again shell script text executable
855f0216bdSXin LI!:mime	text/x-shellscript
86b6cee71dSXin LI
87*2726a701SXin LI# Fish shell magic
88*2726a701SXin LI# From: Benjamin Lowry <ben@ben.gmbh>
89*2726a701SXin LI0	string/wt	#!\ /usr/local/bin/fish		fish shell script text executable
90*2726a701SXin LI!:mime	text/x-shellscript
91*2726a701SXin LI0	string/wt	#!\ /usr/bin/fish		fish shell script text executable
92*2726a701SXin LI!:mime	text/x-shellscript
93*2726a701SXin LI0	string/wt	#!\ /usr/bin/env\ fish		fish shell script text executable
94*2726a701SXin LI!:mime	text/x-shellscript
95*2726a701SXin LI
96*2726a701SXin LI
97*2726a701SXin LI0	search/1/wt	#!\ /usr/bin/tclsh	Tcl/Tk script text executable
98*2726a701SXin LI!:mime  text/x-tcl
99*2726a701SXin LI
100*2726a701SXin LI0	search/1/wt	#!\ /usr/bin/texlua	LuaTex script text executable
101*2726a701SXin LI!:mime	text/x-luatex
102*2726a701SXin LI
103*2726a701SXin LI0	search/1/wt	#!\ /usr/bin/luatex	LuaTex script text executable
104*2726a701SXin LI!:mime	text/x-luatex
105*2726a701SXin LI
106*2726a701SXin LI0	search/1/wt	#!\ /usr/bin/stap	Systemtap script text executable
107*2726a701SXin LI!:mime  text/x-systemtap
108*2726a701SXin LI
109*2726a701SXin LI
110*2726a701SXin LI
111b6cee71dSXin LI# PHP scripts
112b6cee71dSXin LI# Ulf Harnhammar <ulfh@update.uu.se>
113b6cee71dSXin LI0	search/1/c	=<?php			PHP script text
11440427ccaSGordon Tetlow!:strength + 30
115b6cee71dSXin LI!:mime	text/x-php
116b6cee71dSXin LI0	search/1	=<?\n			PHP script text
117b6cee71dSXin LI!:mime	text/x-php
118b6cee71dSXin LI0	search/1	=<?\r			PHP script text
119b6cee71dSXin LI!:mime	text/x-php
120b6cee71dSXin LI0	search/1/w	#!\ /usr/local/bin/php	PHP script text executable
121b6cee71dSXin LI!:strength + 10
122b6cee71dSXin LI!:mime	text/x-php
123b6cee71dSXin LI0	search/1/w	#!\ /usr/bin/php	PHP script text executable
124b6cee71dSXin LI!:strength + 10
125b6cee71dSXin LI!:mime	text/x-php
12648c779cdSXin LI# Smarty compiled template, https://www.smarty.net/
127b6cee71dSXin LI# Elan Ruusamae <glen@delfi.ee>
1283e41d09dSXin LI0	string	=<?php
1293e41d09dSXin LI>5	regex	[\ \n]
1303e41d09dSXin LI>>6	string	/*\ Smarty\ version		Smarty compiled template
13120f8619dSXin LI>>>24	regex	[0-9.]+				\b, version %s
132b6cee71dSXin LI!:mime	text/x-php
133b6cee71dSXin LI
134b6cee71dSXin LI0	string		Zend\x00		PHP script Zend Optimizer data
135b6cee71dSXin LI
136b6cee71dSXin LI0	string/t	$!			DCL command file
137b6cee71dSXin LI
138b6cee71dSXin LI# Type: Pdmenu
13948c779cdSXin LI# URL:  https://packages.debian.org/pdmenu
140b6cee71dSXin LI# From: Edward Betts <edward@debian.org>
141b6cee71dSXin LI0	string		#!/usr/bin/pdmenu	Pdmenu configuration file text
142a5d223e6SXin LI
143a5d223e6SXin LI# From Danny Weldon
144a5d223e6SXin LI0	string	\x0b\x13\x08\x00
145a5d223e6SXin LI>0x04   uleshort	<4      ksh byte-code version %d
146