mirror of
https://github.com/PartialVolume/shredos.x86_64.git
synced 2026-02-20 09:35:26 +00:00
Nwipe can now be configured from the kernel command line in grub.cfg using nwipe_options...., likewise the keyboard layout can be set from the kernel command line in grub.cfg using loadkeys=uk etc. A pause was added on nwipe exit so the summary table could be read. Pressing a key then starts a 5 second countdown to launch nwipe. Added the following additional software packages, memtest86, usbutils for usb-devices command etc, hwdata usb and pci, hidapi, libgudev, dosfstools, includes fatlabel, fsck.fat, mkfs.fat, e2fsprogs, includes fsck.
This commit is contained in:
@@ -3,9 +3,49 @@
|
||||
# trap the ctrl+c signal
|
||||
trap "echo" INT
|
||||
|
||||
# initialise
|
||||
country_code=""
|
||||
nwipe_options_string=""
|
||||
|
||||
# read the kernel command line for the loadkeys label for setting the correct keyboard layout
|
||||
country_code=$(kernel_cmdline_extractor loadkeys)
|
||||
if [ $? == 0 ]
|
||||
then
|
||||
if [ "$country_code" != "" ]
|
||||
then
|
||||
loadkeys $country_code
|
||||
fi
|
||||
fi
|
||||
|
||||
# read the kernel command line for nwipe options
|
||||
nwipe_options_string=$(kernel_cmdline_extractor nwipe_options)
|
||||
if [ $? == 0 ]
|
||||
then
|
||||
nwipe_options_flag=1
|
||||
else
|
||||
nwipe_options_flag=0
|
||||
fi
|
||||
|
||||
# run nwipe with a time stamped log file
|
||||
while true
|
||||
do
|
||||
if [ $nwipe_options_flag == 0 ]
|
||||
then
|
||||
/usr/bin/nwipe --logfile=nwipe_log_$(date +%Y%m%d-%H%M%S).txt
|
||||
else
|
||||
/usr/bin/nwipe --logfile=nwipe_log_$(date +%Y%m%d-%H%M%S).txt $nwipe_options_string
|
||||
fi
|
||||
printf "Paused, press a key to restart nwipe."
|
||||
read -rsn1 input
|
||||
sleep 1;
|
||||
printf " 4"
|
||||
sleep 1
|
||||
printf " 3"
|
||||
sleep 1;
|
||||
printf " 2"
|
||||
sleep 1
|
||||
printf " 1"
|
||||
sleep 1;
|
||||
printf " 0"
|
||||
done
|
||||
|
||||
|
||||
@@ -14,13 +14,23 @@ BR2_LINUX_KERNEL=y
|
||||
BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y
|
||||
BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/shredos/kernel-5.6-defconfig.config"
|
||||
BR2_PACKAGE_BINUTILS=y
|
||||
BR2_PACKAGE_DOSFSTOOLS=y
|
||||
BR2_PACKAGE_DOSFSTOOLS_FATLABEL=y
|
||||
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
|
||||
BR2_PACKAGE_DOSFSTOOLS_MKFS_FAT=y
|
||||
BR2_PACKAGE_E2FSPROGS=y
|
||||
BR2_PACKAGE_HDPARM=y
|
||||
BR2_PACKAGE_HWDATA=y
|
||||
BR2_PACKAGE_KBD=y
|
||||
BR2_PACKAGE_MEMTEST86=y
|
||||
BR2_PACKAGE_SMARTMONTOOLS=y
|
||||
BR2_PACKAGE_TRIGGERHAPPY=y
|
||||
BR2_PACKAGE_USBUTILS=y
|
||||
BR2_PACKAGE_HIDAPI=y
|
||||
BR2_PACKAGE_LIBATASMART=y
|
||||
BR2_PACKAGE_LIBHID=y
|
||||
BR2_PACKAGE_ELFUTILS=y
|
||||
BR2_PACKAGE_KERNEL_CMDLINE_EXTRACTOR=y
|
||||
BR2_PACKAGE_NWIPE=y
|
||||
BR2_PACKAGE_UTIL_LINUX_BINARIES=y
|
||||
BR2_PACKAGE_UTIL_LINUX_MOUNT=y
|
||||
|
||||
@@ -1799,6 +1799,7 @@ menu "Other"
|
||||
source "package/gsl/Config.in"
|
||||
source "package/gtest/Config.in"
|
||||
source "package/jemalloc/Config.in"
|
||||
source "package/kernel_cmdline_extractor/Config.in"
|
||||
source "package/lapack/Config.in"
|
||||
source "package/libargtable2/Config.in"
|
||||
source "package/libatomic_ops/Config.in"
|
||||
|
||||
6
package/kernel_cmdline_extractor/Config.in
Normal file
6
package/kernel_cmdline_extractor/Config.in
Normal file
@@ -0,0 +1,6 @@
|
||||
config BR2_PACKAGE_KERNEL_CMDLINE_EXTRACTOR
|
||||
bool "kernel_cmdline_extractor"
|
||||
help
|
||||
Kernel_cmdline_extractor
|
||||
|
||||
comment "kernel_cmdline_extractor"
|
||||
@@ -0,0 +1 @@
|
||||
sha1 c81a245e89ceb09b28634c6040eef65276e0f51d kernel_cmdline_extractor-v1.04.tar.gz
|
||||
17
package/kernel_cmdline_extractor/kernel_cmdline_extractor.mk
Normal file
17
package/kernel_cmdline_extractor/kernel_cmdline_extractor.mk
Normal file
@@ -0,0 +1,17 @@
|
||||
################################################################################
|
||||
#
|
||||
# kernel_cmdline_extractor
|
||||
#
|
||||
################################################################################
|
||||
|
||||
KERNEL_CMDLINE_EXTRACTOR_VERSION = v1.04
|
||||
KERNEL_CMDLINE_EXTRACTOR_SITE = $(call github,PartialVolume,kernel_cmdline_extractor,$(KERNEL_CMDLINE_EXTRACTOR_VERSION))
|
||||
|
||||
define KERNEL_CMDLINE_EXTRACTOR_INITSH
|
||||
(cd $(@D) && ./autogen.sh);
|
||||
endef
|
||||
|
||||
KERNEL_CMDLINE_EXTRACTOR_POST_PATCH_HOOKS += KERNEL_CMDLINE_EXTRACTOR_INITSH
|
||||
|
||||
|
||||
$(eval $(autotools-package))
|
||||
Reference in New Issue
Block a user