From 05b5884f419da45b1640b2bb354154c81175c46a Mon Sep 17 00:00:00 2001 From: Uri Herrera Date: Tue, 13 Jun 2023 02:08:59 -0600 Subject: [PATCH] update pkg --- debian/changelog | 12 +++++++++--- usr/bin/nuts | 10 +++++++--- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index 3d87e5c..7a3ce3c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,14 +1,20 @@ +nuts (0.1.0) nitrux; urgency=medium + + * Revise ISO check. + + -- Uri Herrera Tue, 13 Jun 2023 02:08:00 -0500 + nuts (0.0.9) nitrux; urgency=medium * Check if ISO exists so it's not downloaded again. - -- Uri Herrera Thu, 13 Jun 2023 01:47:00 -0500 + -- Uri Herrera Tue, 13 Jun 2023 01:47:00 -0500 nuts (0.0.8) nitrux; urgency=medium * Revise aria2c command. - -- Uri Herrera Thu, 13 Jun 2023 01:47:00 -0500 + -- Uri Herrera Tue, 13 Jun 2023 01:47:00 -0500 nuts (0.0.7) nitrux; urgency=medium @@ -16,7 +22,7 @@ nuts (0.0.7) nitrux; urgency=medium * Revise aria2c command. * Revise axel command. - -- Uri Herrera Thu, 13 Jun 2023 01:34:00 -0500 + -- Uri Herrera Tue, 13 Jun 2023 01:34:00 -0500 nuts (0.0.6) nitrux; urgency=medium diff --git a/usr/bin/nuts b/usr/bin/nuts index c1cd8da..817c4bd 100755 --- a/usr/bin/nuts +++ b/usr/bin/nuts @@ -304,18 +304,22 @@ case "$1" in # -- Download the ISO with aria2c using the BitTorrent protocol. - # -- Check if the ISO already exists so it's not downloaded again. + # -- Check if the ISO already exists so it's not downloaded again. If an ISO file was downloaded then rename it. # -- However, If the ISO file found doesn't match the checksum, it will still cause the utility to exit at a later stage. # -- Use the magnet link from the query file. # -- Magnet link is provided by FOSS Torrents https://fosstorrents.com/distributions/nitrux/#downloads. - if [ -f "$NUTS_DIR_DLS/nitrux.iso" ]; then - puts-info "An ISO file was found, skipping..." + if [ ! -f "$NUTS_DIR_DLS/nitrux.iso" ]; then + puts-info "ISO file not found! Checking for other ISO files, continuing..." + if [ -f "$NUTS_DIR_DLS/nitrux-nx-desktop-plasma-*-amd64.iso" ]; then + $ROOT mv "$NUTS_DIR_DLS"/nitrux-nx-desktop-plasma-*-amd64.iso "$NUTS_DIR_DLS"/nitrux.iso + fi else 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 + fi