treewide: drop shebang from non-executable target files

This drops the shebang from all target files for /lib and
/etc/uci-defaults folders, as these are sourced and the shebang
is useless.

While at it, fix the executable flag on a few of these files.

This does not touch ar71xx, as this target is just used for
backporting now and applying cosmetic changes would just complicate
things.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
This commit is contained in:
Adrian Schmutzler 2020-06-06 23:13:41 +02:00
parent b7a8a54542
commit 48c1fdd046
61 changed files with 4 additions and 99 deletions

View File

@ -1,5 +1,3 @@
#!/bin/sh
preinit_set_mac_address() {
. /lib/functions.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
apm821xx_set_preinit_iface() {
ifname=eth0
}

View File

@ -1,5 +1,3 @@
#!/bin/sh
BOOTPART=/dev/sda1
move_config() {

View File

@ -1,5 +1,3 @@
#!/bin/sh
PART_NAME=firmware
REQUIRE_IMAGE_METADATA=1

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2015 OpenWrt.org
#

View File

@ -1,9 +1,7 @@
#!/bin/sh
do_arc() {
. /lib/arc.sh
. /lib/arc.sh
arc_board_detect
arc_board_detect
}
boot_hook_add preinit_main do_arc

View File

@ -1,9 +1,7 @@
#!/bin/sh
do_arc() {
. /lib/arc.sh
. /lib/arc.sh
arc_board_detect
arc_board_detect
}
boot_hook_add preinit_main do_arc

1
target/linux/at91/base-files/lib/at91.sh Executable file → Normal file
View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2014 OpenWrt.org
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
do_at91() {
. /lib/at91.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
# reset button only supported on ar5315+ at the moment
preinit_ip() {
if [ -z "$pi_ifname" ]; then

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/migrations.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
. /lib/functions.sh
fix_seama_header() {

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2018 Weijie Gao <hackpascal@gmail.com>
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
preinit_set_mac_address() {

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/migrations.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2015-2016 OpenWrt.org
# Copyright (C) 2017 LEDE project

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2015 OpenWrt.org
. /lib/upgrade/common.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2014-2015 OpenWrt.org
#

View File

@ -1,7 +1,5 @@
#!/bin/sh
#
# Copyright (C) 2007 OpenWrt.org
#
#
mtd fixtrx firmware

View File

@ -1,5 +1,3 @@
#!/bin/sh
do_sysinfo_bcm47xx() {
local boardtype="$(nvram get boardtype)"
local boardnum="$(nvram get boardnum)"

View File

@ -1,5 +1,3 @@
#!/bin/sh
kernel_size=$(sed -n 's/mtd[0-9]*: \([0-9a-f]*\).*"\(kernel\|linux\)".*/\1/p' /proc/mtd)
mtd ${kernel_size:+-c 0x$kernel_size} fixtrx firmware && exit 0

View File

@ -1,8 +1,6 @@
#!/bin/sh
#
# Copyright (C) 2007 OpenWrt.org
#
#
. /lib/functions.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
CNS3XXX_BOARD_NAME=
CNS3XXX_MODEL=

View File

@ -1,5 +1,3 @@
#!/bin/sh
do_sysinfo_cns3xxx() {
. /lib/cns3xxx.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2019 OpenWrt.org
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/system.sh

1
target/linux/imx6/base-files/lib/imx6.sh Executable file → Normal file
View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2010-2013 OpenWrt.org
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
do_sysinfo_imx6() {
. /lib/imx6.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/imx6.sh
. /lib/functions.sh
. /lib/upgrade/common.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
preinit_set_mac_address() {

View File

@ -1,5 +1,3 @@
#!/bin/sh
set_preinit_iface() {
. /lib/functions.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2018 OpenWrt.org
#

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2013 OpenWrt.org
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
IFNAME_CHANGED=0

View File

@ -1,5 +1,3 @@
#!/bin/sh
reorder_layerscape_interfaces() {
if [ ! -f /tmp/sysinfo/board_name ]; then
echo "No board name found, not doing reorder_layerscape_interfaces"

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright 2015-2019 Traverse Technologies
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
set_preinit_iface() {
ifconfig eth0 up
ifname=lan1

View File

@ -1,5 +1,3 @@
#!/bin/sh
set_rps_sock_flow() {
echo 1024 > /proc/sys/net/core/rps_sock_flow_entries
}

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2018 OpenWrt.org
RECOVERY_PART=/dev/mmcblk0p1

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2015 OpenWrt.org
. /lib/upgrade/common.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2013 OpenWrt.org
#

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2015 OpenWrt.org
. /lib/functions.sh

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2015 OpenWrt.org
#

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2017 LEDE-Project.org
#

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2014 OpenWrt.org
move_config() {

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2012-2015 OpenWrt.org
move_config() {

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2017 OpenWrt.org
#

View File

@ -1,4 +1,3 @@
#!/bin/sh
#
# Copyright (C) 2012 OpenWrt.org
#

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/migrations.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/migrations.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
mt7621_bringup_dsa_master() {

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/migrations.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
. /lib/functions.sh
. /lib/functions/migrations.sh

View File

@ -1,5 +1,3 @@
#!/bin/sh
# Netgear WNCE2001 has does a checksum check on boot and goes into recovery
# tftp mode when the check fails. Initializing the JFFS2 partition triggers
# this, so we make sure to zero checksum and size to be checksummed before

View File

@ -1,5 +1,3 @@
#!/bin/sh
# Netgear WNCE2001 has does a checksum check on boot and goes into recovery
# tftp mode when the check fails. Initializing the JFFS2 partition triggers
# this, so we make sure to zero checksum and size to be checksummed before

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2010 OpenWrt.org
do_mount_xenfs() {

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2018 OpenWrt.org
do_load_x86_ucode() {

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2006-2010 OpenWrt.org
# Copyright (C) 2010 Vertical Communications

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2012-2015 OpenWrt.org
move_config() {

View File

@ -1,5 +1,3 @@
#!/bin/sh
upgrade_bootloader() {
local diskdev

View File

@ -1,4 +1,3 @@
#!/bin/sh
# Copyright (C) 2010 OpenWrt.org
do_mount_xenfs() {