[OpenWrt-Devel] execute bit in board.d files

mail at adrianschmutzler.de mail at adrianschmutzler.de
Sun Aug 4 09:36:21 EDT 2019


I was just wondering why the execute bit for board.d subfiles is set.

In package/base-files/files/bin/board_detect:
[ -d "/etc/board.d/" -a ! -s "$CFG" ] && {
	for a in `ls /etc/board.d/*`; do
		[ -x $a ] || continue;
		$(. $a)

So, to me it looks like the files are only sourced (preceding dot) and thus both the execute check as well as the execute bit are not required?

Despite, can someone explain me the purpose of the surrounding $() for $(. $a) ?


-------------- next part --------------
A non-text attachment was scrubbed...
Name: openpgp-digital-signature.asc
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/openwrt-devel/attachments/20190804/87d81c88/attachment.sig>
-------------- next part --------------
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org

More information about the openwrt-devel mailing list