repo.or.cz
/
cmdllinux.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
some modification on instpkg
[cmdllinux.git]
/
scripts
/
_find_shell_scripts.sh
blob
b4b06c6e23ee6c5fe088f5e6fb481cc4909c4f54
1
#text and script
2
[
"
$1
"
=
"-t"
] &&
text
=
1
3
4
find
-type
f | \
5
while
read
file
;
do
6
output
=
`file
$file
`
7
if
[
$text
];
then
8
if
echo
"
$output
"
|
grep
-q
"POSIX shell script\|ASCII text"
;
then
9
echo
$file
10
fi
11
else
12
if
echo
"
$output
"
|
grep
-q
"POSIX shell script"
;
then
13
echo
$file
14
fi
15
fi
16
done