Skip to content

Commit

Permalink
pre-release cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
morrownr committed Jan 30, 2023
1 parent 2e46b96 commit 0ae6dec
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 5 deletions.
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -745,8 +745,17 @@ Contributors:
@tamojitray
@amisix
@henkv1
@SubZero5

----
-----

To-Do:

- Test for installation in VM's.
- Optimize scripts.
- Installation script needs to check country code setup.

-----

#### [Go to Main Menu](https://github.com/morrownr/USB-WiFi)

Expand Down
10 changes: 9 additions & 1 deletion install-driver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ SCRIPT_VERSION="20230126"
MODULE_NAME="8821cu"
DRV_VERSION="5.12.0.4"

KVER="$(uname -r)"
KARCH="$(uname -m)"
KVER="$(uname -r)"
MODDESTDIR="/lib/modules/${KVER}/kernel/drivers/net/wireless/"

DRV_NAME="rtl${MODULE_NAME}"
Expand Down Expand Up @@ -74,6 +74,14 @@ if ! command -v gcc >/dev/null 2>&1; then
exit 1
fi

# check to ensure bc is installed
if ! command -v bc >/dev/null 2>&1; then
echo "A required package is not installed."
echo "Please install the following package: bc"
echo "Once the package is installed, please run \"sudo ./${SCRIPT_NAME}\""
exit 1
fi

# check to ensure make is installed
if ! command -v make >/dev/null 2>&1; then
echo "A required package is not installed."
Expand Down
6 changes: 3 additions & 3 deletions remove-driver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ SCRIPT_VERSION="20230126"
MODULE_NAME="8821cu"
DRV_VERSION="5.12.0.4"

KVER="$(uname -r)"
KARCH="$(uname -m)"
KVER="$(uname -r)"
MODDESTDIR="/lib/modules/${KVER}/kernel/drivers/net/wireless/"

DRV_NAME="rtl${MODULE_NAME}"
Expand Down Expand Up @@ -67,7 +67,7 @@ echo ": ${SCRIPT_NAME} v${SCRIPT_VERSION}"
# information that helps with bug reports

# display architecture
echo ": ${KARCH} (architecture"
echo ": ${KARCH} (architecture)"

# display kernel version
echo ": ${KVER} (kernel version)"
Expand Down Expand Up @@ -132,7 +132,7 @@ echo "You may now delete the driver directory if desired."

# if NoPrompt is not used, ask user some questions
if [ $NO_PROMPT -ne 1 ]; then
printf "Do you want to apply the new options by rebooting now? (recommended) [y/N] "
printf "Do you want to reboot now? (recommended) [y/N] "
read -r REPLY
case "$REPLY" in
[yY]*) reboot ;;
Expand Down

0 comments on commit 0ae6dec

Please sign in to comment.