From d8af2e6f85e35d7a00c21a69506cf54c744576bf Mon Sep 17 00:00:00 2001
From: Holden Rohrer
Date: Fri, 29 May 2020 15:12:00 -0400
Subject: using dhcpcd's wpa_supplicant hook
This removes the failure of an interface determiner in build.sh
---
build.sh | 1 -
config.sh | 4 ++--
src/etc/wpa_supplicant.conf | 17 +++++++++++++++++
src/etc/wpa_supplicant/wpa_supplicant.conf | 17 -----------------
src/usr/lib/dhcpcd/dhcpcd-hooks/10-wpa_supplicant | 1 +
5 files changed, 20 insertions(+), 20 deletions(-)
create mode 100644 src/etc/wpa_supplicant.conf
delete mode 100644 src/etc/wpa_supplicant/wpa_supplicant.conf
create mode 120000 src/usr/lib/dhcpcd/dhcpcd-hooks/10-wpa_supplicant
diff --git a/build.sh b/build.sh
index 7c2291b..f466004 100755
--- a/build.sh
+++ b/build.sh
@@ -29,7 +29,6 @@ sh source.sh
grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=GRUB
grub-mkconfig -o /boot/grub/grub.cfg
mkinitcpio -P
-systemctl enable wpa_supplicant@$(basename /sys/class/net/wl*)
sed 's:#.*$::' services | xargs systemctl enable
passwd
diff --git a/config.sh b/config.sh
index 5fac5ed..d13189a 100755
--- a/config.sh
+++ b/config.sh
@@ -4,12 +4,12 @@
for file in $(find src -type f); do
export clean=$(echo $file | cut -c 4-) #Removes src prefix
mkdir -p $(dirname $clean)
- cp $file $clean
+ cp -P $file $clean
done
for file in $(find home -type f); do
export clean=/home/${USE}$(echo $file | cut -c 5-)
mkdir -p $(dirname $clean)
- cp $file $clean
+ cp -P $file $clean
done
chown -R ${USE}:${USE} /home/${USE}
diff --git a/src/etc/wpa_supplicant.conf b/src/etc/wpa_supplicant.conf
new file mode 100644
index 0000000..106bb82
--- /dev/null
+++ b/src/etc/wpa_supplicant.conf
@@ -0,0 +1,17 @@
+ctrl_interface=/var/run/wpa_supplicant
+update_config=1
+
+network={
+ ssid="404 Network Not Found"
+ psk="easypeasy"
+}
+
+network={
+ ssid="Bruh Moment"
+ psk="vroomvroom"
+}
+
+network={
+ key_mgmt=NONE
+ priority=-999
+}
diff --git a/src/etc/wpa_supplicant/wpa_supplicant.conf b/src/etc/wpa_supplicant/wpa_supplicant.conf
deleted file mode 100644
index 106bb82..0000000
--- a/src/etc/wpa_supplicant/wpa_supplicant.conf
+++ /dev/null
@@ -1,17 +0,0 @@
-ctrl_interface=/var/run/wpa_supplicant
-update_config=1
-
-network={
- ssid="404 Network Not Found"
- psk="easypeasy"
-}
-
-network={
- ssid="Bruh Moment"
- psk="vroomvroom"
-}
-
-network={
- key_mgmt=NONE
- priority=-999
-}
diff --git a/src/usr/lib/dhcpcd/dhcpcd-hooks/10-wpa_supplicant b/src/usr/lib/dhcpcd/dhcpcd-hooks/10-wpa_supplicant
new file mode 120000
index 0000000..24a1bce
--- /dev/null
+++ b/src/usr/lib/dhcpcd/dhcpcd-hooks/10-wpa_supplicant
@@ -0,0 +1 @@
+/usr/share/dhcpcd/hooks/10-wpa_supplicant
\ No newline at end of file
--
cgit