base-files: remove shebang from uci-defaults files
authorAdrian Schmutzler <freifunk@adrianschmutzler.de>
Thu, 7 Nov 2019 21:29:21 +0000 (22:29 +0100)
committerAdrian Schmutzler <freifunk@adrianschmutzler.de>
Wed, 13 Nov 2019 11:50:57 +0000 (12:50 +0100)
uci-defaults are sourced and non-executable, so they do not require
a shebang.

While at it, apply consistent naming scheme.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
package/base-files/Makefile
package/base-files/files/etc/uci-defaults/10_migrate-shadow
package/base-files/files/etc/uci-defaults/12_network-generate-ula
package/base-files/files/etc/uci-defaults/13_fix-group-user [new file with mode: 0644]
package/base-files/files/etc/uci-defaults/13_fix_group_user [deleted file]

index 5c121ac..b35d00c 100644 (file)
@@ -12,7 +12,7 @@ include $(INCLUDE_DIR)/version.mk
 include $(INCLUDE_DIR)/feeds.mk
 
 PKG_NAME:=base-files
-PKG_RELEASE:=207
+PKG_RELEASE:=208
 PKG_FLAGS:=nonshared
 
 PKG_FILE_DEPENDS:=$(PLATFORM_DIR)/ $(GENERIC_PLATFORM_DIR)/base-files/
index a354844..481444f 100644 (file)
@@ -1,5 +1,3 @@
-#!/bin/sh
-
 ppwd="$(sed -ne '/^root:/s/^root:\([^:]*\):.*$/\1/p' /etc/passwd)"
 spwd="$(sed -ne '/^root:/s/^root:\([^:]*\):.*$/\1/p' /etc/shadow)"
 
index 8871427..19d7ed7 100644 (file)
@@ -1,5 +1,3 @@
-#!/bin/sh
-
 [ "$(uci -q get network.globals.ula_prefix)" != "auto" ] && exit 0
 
 r1=$(dd if=/dev/urandom bs=1 count=1 |hexdump -e '1/1 "%02x"')
diff --git a/package/base-files/files/etc/uci-defaults/13_fix-group-user b/package/base-files/files/etc/uci-defaults/13_fix-group-user
new file mode 100644 (file)
index 0000000..bf9febd
--- /dev/null
@@ -0,0 +1,9 @@
+. /lib/functions.sh
+
+for file in `grep -sl Require-User /usr/lib/opkg/info/*.control`; do
+       file="${file##*/}"
+       file="${file%.control}"
+       add_group_and_user "${file}"
+done
+
+exit 0
diff --git a/package/base-files/files/etc/uci-defaults/13_fix_group_user b/package/base-files/files/etc/uci-defaults/13_fix_group_user
deleted file mode 100644 (file)
index e6dae24..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-. /lib/functions.sh
-
-for file in `grep -sl Require-User /usr/lib/opkg/info/*.control`; do
-       file="${file##*/}"
-       file="${file%.control}"
-       add_group_and_user "${file}"
-done
-
-exit 0