From ee330bfd8a0bdc45b2e389d0828cb7eb9012aaaf Mon Sep 17 00:00:00 2001 From: Uri Herrera Date: Tue, 13 Jun 2023 01:34:12 -0600 Subject: [PATCH] :laughing: ofc it didn't work; fix comparison --- debian/changelog | 8 ++++++++ usr/bin/nuts | 11 +++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index 8188b0a..9f074cb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +nuts (0.0.7) nitrux; urgency=medium + + * Fix ISO comparison. + * Revise aria2c command. + * Revise axel command. + + -- Uri Herrera Mon, 12 Jun 2023 22:34:00 -0500 + nuts (0.0.6) nitrux; urgency=medium * Fix chroot messages, download aria2 when using versions of the distribution without it. diff --git a/usr/bin/nuts b/usr/bin/nuts index 0163267..dd7513d 100755 --- a/usr/bin/nuts +++ b/usr/bin/nuts @@ -95,7 +95,7 @@ fi # -- Functions. -dl_file () { axel -a -o /tmp -n 10 "$@"; } +dl_file () { axel -o /tmp -n 10 "$@"; } overlay_ch () { $ROOT overlayroot-chroot; } @@ -275,7 +275,7 @@ case "$1" in -e /media/* \ -e /run/* \ -e /sys/* \ - -e /tmp/* \ + -e //tmp/* \ -e /var/{cache,lib,local,lock,log,mail,opt,run,spool,tmp}/ \ -comp zstd \ -Xcompression-level 22 \ @@ -307,17 +307,16 @@ case "$1" in # -- Use the magnet link from the query file. # -- Magnet link is provided by FOSS Torrents https://fosstorrents.com/distributions/nitrux/#downloads. + puts-info "Dowloading ISO using aria2c, continuing..." MAGNET_LINK="$(tail /tmp/nuts-query.info | grep magnetlink= | rev | cut -d '=' -f -42 | rev)" - - $ROOT aria2c -d "$NUTS_DIR_DLS" --seed-time=0 "$MAGNET_LINK" - $ROOT mv "$NUTS_DIR_DLS"/nitrux-nx-desktop-plasma-*-amd64.iso "$NUTS_DIR_DLS"/nitrux.iso + $ROOT aria2c -d "$NUTS_DIR_DLS" -o nitrux.iso --seed-time=0 "$MAGNET_LINK" # -- Verify the checksum of the ISO. Use the checksum from the query file. # -- Exit if checksum doesn't match. LOCAL_ISO_SUM="$(md5sum "$NUTS_DIR_DLS"/nitrux.iso | cut -c -32)" - DL_ISO_SUM="$(tail /tmp/nuts-query.info | grep rootlistsum= | cut -c -44 | rev | cut -c -32 | rev)" + DL_ISO_SUM="$(tail /tmp/nuts-query.info | grep isosum= | cut -c -44 | rev | cut -c -32 | rev)" if [ "$LOCAL_ISO_SUM" == "$DL_ISO_SUM" ]; then puts-info "ISO checksum matches, continuing..."