2015-12-08 11:55:29 +00:00
|
|
|
#!/bin/sh
|
|
|
|
FILES="
|
2017-03-09 01:13:09 +00:00
|
|
|
libr/util/mem.c
|
2017-02-12 21:44:13 +00:00
|
|
|
libr/util/base64.c
|
|
|
|
libr/util/name.c
|
|
|
|
libr/util/idpool.c
|
|
|
|
libr/util/stack.c
|
|
|
|
libr/util/slist.c
|
|
|
|
libr/util/log.c
|
|
|
|
libr/util/cache.c
|
|
|
|
libr/util/print.c
|
|
|
|
|
2017-02-28 01:26:55 +00:00
|
|
|
libr/asm/p/asm_bf.c
|
|
|
|
|
2017-02-26 23:40:25 +00:00
|
|
|
libr/hash/calc.c
|
|
|
|
libr/hash/crc16.c
|
|
|
|
libr/hash/luhn.c
|
|
|
|
libr/hash/xxhash.c
|
|
|
|
libr/hash/md4.c
|
|
|
|
libr/hash/adler32.c
|
|
|
|
libr/hash/hash.c
|
|
|
|
libr/hash/sha2.c
|
|
|
|
|
2017-02-12 21:44:13 +00:00
|
|
|
libr/reg/reg.c
|
|
|
|
libr/reg/arena.c
|
|
|
|
libr/reg/double.c
|
|
|
|
libr/reg/cond.c
|
|
|
|
libr/reg/value.c
|
|
|
|
libr/reg/profile.c
|
|
|
|
|
2015-12-08 23:41:44 +00:00
|
|
|
libr/include/r_list.h
|
|
|
|
libr/include/r_reg.h
|
2017-02-12 21:44:13 +00:00
|
|
|
libr/include/r_util.h
|
|
|
|
|
2017-03-09 22:45:26 +00:00
|
|
|
libr/anal/var.c
|
|
|
|
libr/anal/fcn.c
|
2015-12-14 13:32:18 +00:00
|
|
|
libr/anal/cycles.c
|
|
|
|
libr/anal/esil.c
|
|
|
|
libr/anal/data.c
|
2017-03-09 22:45:26 +00:00
|
|
|
libr/anal/flirt.c
|
2016-05-18 08:02:35 +00:00
|
|
|
libr/anal/p/anal_arc.c
|
2017-02-12 21:44:13 +00:00
|
|
|
|
2015-12-08 23:41:44 +00:00
|
|
|
libr/config/config.c
|
|
|
|
libr/config/callback.c
|
|
|
|
libr/config/t/test.c
|
2017-02-12 21:44:13 +00:00
|
|
|
|
2015-12-08 23:41:44 +00:00
|
|
|
libr/fs/fs.c
|
2017-02-12 21:44:13 +00:00
|
|
|
libr/fs/file.c
|
|
|
|
|
2015-12-08 22:55:23 +00:00
|
|
|
libr/bin/bin.c
|
|
|
|
libr/bin/bin_write.c
|
|
|
|
libr/bin/dbginfo.c
|
|
|
|
libr/bin/filter.c
|
|
|
|
libr/bin/format/objc/mach0_classes.c
|
2017-02-12 21:44:13 +00:00
|
|
|
|
2015-12-08 11:55:29 +00:00
|
|
|
libr/cons/hud.c
|
|
|
|
libr/cons/2048.c
|
2016-01-07 11:04:26 +00:00
|
|
|
libr/cons/utf8.c
|
2017-03-19 02:21:40 +00:00
|
|
|
libr/cons/grep.c
|
2015-12-08 11:55:29 +00:00
|
|
|
libr/cons/line.c
|
|
|
|
libr/cons/canvas.c
|
2015-12-08 12:24:21 +00:00
|
|
|
libr/cons/editor.c
|
2017-02-12 21:44:13 +00:00
|
|
|
|
2016-01-07 11:04:26 +00:00
|
|
|
libr/core/file.c
|
2017-02-10 01:05:58 +00:00
|
|
|
libr/core/yank.c
|
|
|
|
libr/core/blaze.c
|
2017-03-09 22:45:26 +00:00
|
|
|
libr/core/cmd_egg.c
|
2017-02-12 21:44:13 +00:00
|
|
|
|
2017-11-07 07:47:39 +00:00
|
|
|
shlr/tcc/tccgen.c
|
|
|
|
shlr/tcc/libtcc.c
|
|
|
|
shlr/tcc/tccpp.c
|
|
|
|
|
2017-02-12 21:44:13 +00:00
|
|
|
binr/radare2/radare2.c
|
|
|
|
binr/rabin2/rabin2.c
|
2017-03-19 02:21:40 +00:00
|
|
|
binr/radiff2/radiff2.c
|
2016-03-30 14:26:46 +00:00
|
|
|
binr/rasm2/rasm2.c
|
2017-02-10 01:05:58 +00:00
|
|
|
binr/rax2/rax2.c
|
2015-12-08 11:55:29 +00:00
|
|
|
"
|
2017-03-09 01:13:09 +00:00
|
|
|
|
|
|
|
chk() {
|
|
|
|
if [ -z "$2" ]; then
|
|
|
|
return 0
|
|
|
|
fi
|
|
|
|
echo "$1" | grep -q "$2"
|
|
|
|
}
|
|
|
|
|
2015-12-08 21:35:39 +00:00
|
|
|
case "$1" in
|
2017-03-09 01:13:09 +00:00
|
|
|
help|-h)
|
|
|
|
echo "Usage. sys/indent-whitelist.sh [--fix] [regex]"
|
2015-12-08 21:35:39 +00:00
|
|
|
;;
|
2017-03-09 01:13:09 +00:00
|
|
|
--fix)
|
|
|
|
for f in $FILES ; do
|
|
|
|
chk $f $2 || continue
|
|
|
|
r2pm -r sys/indent.sh -i $f
|
|
|
|
done
|
2015-12-08 21:35:39 +00:00
|
|
|
;;
|
|
|
|
*)
|
2017-03-09 01:13:09 +00:00
|
|
|
for f in $FILES ; do
|
|
|
|
chk $f $1 || continue
|
|
|
|
r2pm -r sys/indent.sh -u $f
|
|
|
|
done
|
2015-12-08 21:35:39 +00:00
|
|
|
esac
|