From 40e5a067ec7f6235ab2daaacc99268c98d3fb1c4 Mon Sep 17 00:00:00 2001 From: "Igor Zalatov (from Citadel PC)" Date: Wed, 31 Aug 2022 21:10:48 +0300 Subject: [PATCH] Fix stapler --- stapler | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/stapler b/stapler index 377812c..99712f1 100755 --- a/stapler +++ b/stapler @@ -13,7 +13,7 @@ RELEASE="" PROJECT="$1" PROJECT="${PROJECT:=t31_vixand}" TFTPSRV="root@172.17.32.17:/mnt/bigger-2tb/Rotator/TFTP" - +OUTTIME=$(date +"%Y%m%d") echo_c() { # 31 red, 32 green, 33 yellow, 34 blue, 35 magenta, 36 cyan, 37 white, 38 grey @@ -22,12 +22,13 @@ echo_c() { } 2tftp() { - echo_c 32 "\nStart transferring files to the TFTP server ...\n" - scp -r $@ ${TFTPSRV} + echo_c 32 "\nStart transferring files to the TFTP server ...\n" + scp -r $@ ${TFTPSRV} } + echo_c 32 "\nAttention, let's start working on the ${PROJECT} project ...\n" git pull rm -rf Firmware @@ -38,7 +39,10 @@ cd Firmware echo_c 35 "\nYou can get the new assembled firmware components here:\n" tree -C output/images 2tftp output/images/rootfs.squashfs.* output/images/uImage.* -mkdir ../Output/${Project}_$(date +"%Y%m%d") -cp -av output/images/rootfs.squashfs.* output/images/uImage.* +mkdir -p ../Output/${PROJECT}_ +cp -av output/images/rootfs.squashfs.* output/images/uImage.* ../Output/${PROJECT}_${OUTTIME} echo_c 35 "\nRollback to home ...\n" cd - + + +# tree -L 1 Projects