From 1d582d8e0cc996bf3c499d7a8f68284e3068ceb2 Mon Sep 17 00:00:00 2001 From: AuxXxilium Date: Mon, 29 Jul 2024 23:04:28 +0200 Subject: [PATCH] tree: cleanup Signed-off-by: AuxXxilium --- files/initrd/opt/arc/arc-functions.sh | 12 ++++-------- files/p1/boot/grub/grub.cfg | 2 +- scripts/random.sh | 7 +++++++ 3 files changed, 12 insertions(+), 9 deletions(-) create mode 100755 scripts/random.sh diff --git a/files/initrd/opt/arc/arc-functions.sh b/files/initrd/opt/arc/arc-functions.sh index 935d96f7..b996fc0b 100755 --- a/files/initrd/opt/arc/arc-functions.sh +++ b/files/initrd/opt/arc/arc-functions.sh @@ -1956,21 +1956,17 @@ function decryptMenu() { --msgbox "Decrypt successful: You can use Arc Patch." 5 50 cp -f "${S_FILE_ARC}" "${S_FILE}" writeConfigKey "arc.key" "${ARC_KEY}" "${USER_CONFIG_FILE}" - writeConfigKey "arc.confdone" "false" "${USER_CONFIG_FILE}" - CONFDONE="$(readConfigKey "arc.confdone" "${USER_CONFIG_FILE}")" - writeConfigKey "arc.builddone" "false" "${USER_CONFIG_FILE}" - BUILDDONE="$(readConfigKey "arc.builddone" "${USER_CONFIG_FILE}")" else cp -f "${S_FILE}.bak" "${S_FILE}" dialog --backtitle "$(backtitle)" --colors --title "Arc Decrypt" \ --msgbox "Decrypt failed: Wrong Key for this Version." 5 50 writeConfigKey "arc.key" "" "${USER_CONFIG_FILE}" - writeConfigKey "arc.confdone" "false" "${USER_CONFIG_FILE}" - CONFDONE="$(readConfigKey "arc.confdone" "${USER_CONFIG_FILE}")" - writeConfigKey "arc.builddone" "false" "${USER_CONFIG_FILE}" - BUILDDONE="$(readConfigKey "arc.builddone" "${USER_CONFIG_FILE}")" fi fi + writeConfigKey "arc.confdone" "false" "${USER_CONFIG_FILE}" + CONFDONE="$(readConfigKey "arc.confdone" "${USER_CONFIG_FILE}")" + writeConfigKey "arc.builddone" "false" "${USER_CONFIG_FILE}" + BUILDDONE="$(readConfigKey "arc.builddone" "${USER_CONFIG_FILE}")" ARC_KEY="$(readConfigKey "arc.key" "${USER_CONFIG_FILE}")" return } diff --git a/files/p1/boot/grub/grub.cfg b/files/p1/boot/grub/grub.cfg index 16050da0..9318974f 100644 --- a/files/p1/boot/grub/grub.cfg +++ b/files/p1/boot/grub/grub.cfg @@ -78,7 +78,7 @@ set menu_color_normal=white/black set menu_color_highlight=white/red set color_normal=white/black -set ARC_CMDLINE="earlyprintk earlycon=uart8250,io,0x3f8,115200n8 console=ttyS0,115200n8 root=/dev/ram rootwait pcie_aspm=off net.ifnames=0 nox2apic nomodeset intremap=off" +set ARC_CMDLINE="earlyprintk earlycon=uart8250,io,0x3f8,115200n8 console=ttyS0,115200n8 root=/dev/ram rootwait pcie_aspm=off net.ifnames=0 nox2apic nomodeset nointremap" search --set=root --label "ARC3" if [ -e /automated ]; then diff --git a/scripts/random.sh b/scripts/random.sh new file mode 100755 index 00000000..6fcc4407 --- /dev/null +++ b/scripts/random.sh @@ -0,0 +1,7 @@ +#!/usr/bin/env bash + +function genRandomValue() { + for i in 0 1 2 3 4 5 6 7 8 9 A B C D E F G H J K L M N P Q R S T V W X Y Z; do + echo ${i} + done | sort -R | tail -1 +} \ No newline at end of file