@eshanized: push via push.sh!!!

This commit is contained in:
2024-03-08 00:54:53 +05:30
parent 5c5d28e494
commit d7c5b1dee6
2 changed files with 8 additions and 3 deletions

View File

@@ -1,4 +1,4 @@
#!bin/bash #!/bin/bash
set -e set -e
# Author : Eshan Roy <eshan@snigdhaos.or> # Author : Eshan Roy <eshan@snigdhaos.or>
@@ -10,6 +10,7 @@ echo
numberofcores=$(grep -c ^processor /proc/cpuinfo) numberofcores=$(grep -c ^processor /proc/cpuinfo)
# shellcheck disable=SC2086
if [ $numberofcores -gt 1 ]; then if [ $numberofcores -gt 1 ]; then
echo "TOTAL CORES : "$numberofcores echo "TOTAL CORES : "$numberofcores
echo "Changing makeflags for "$numberofcores "cores." echo "Changing makeflags for "$numberofcores "cores."

View File

@@ -9,6 +9,7 @@ echo "--->> Start snigdhaos-fixes <<---"
echo echo
kernel_cmdline() { kernel_cmdline() {
# shellcheck disable=SC2013
for param in $(cat /proc/cmdline); do for param in $(cat /proc/cmdline); do
case "${param}" in case "${param}" in
$1=*) echo "${param##*=}"; return 0 ;; $1=*) echo "${param##*=}"; return 0 ;;
@@ -16,11 +17,13 @@ kernel_cmdline(){
*) continue ;; *) continue ;;
esac esac
done done
[ -n "${2}" ] echo "${2}" [ -n "${2}" ] && echo "${2}"
return 1 return 1
} }
get_driver(){ get_driver(){
# shellcheck disable=SC2005
# shellcheck disable=SC2046
echo $(kernel_cmdline driver) echo $(kernel_cmdline driver)
} }
@@ -38,6 +41,7 @@ done
selection=$(get_driver) selection=$(get_driver)
echo echo
# shellcheck disable=SC2086
echo "Your Selection : "$selection echo "Your Selection : "$selection
echo echo