[2024-feb-29] Sad news: Eric Layton aka Nocturnal Slacker aka vtel57 passed away on Feb 26th, shortly after hospitalization. He was one of our Wiki's most prominent admins. He will be missed.

Welcome to the Slackware Documentation Project

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
howtos:hardware:arm:slackwarearm_local-mirror-repository [2021/03/15 15:01 (UTC)] – [Preface] additional text and restructuring exagahowtos:hardware:arm:slackwarearm_local-mirror-repository [2021/04/02 19:22 (UTC)] (current) – [local-slackwarearm-repo.sh script code] revised script header info exaga
Line 5: Line 5:
  
 ===== Preface ===== ===== Preface =====
 +
 +The script featured here, 'local-slackwarearm-repo.sh' [nickname: 'SAREPO'] does not attempt to supplant or undermine the above (or other) contemporary efforts, by //re-inventing the wheel//, so to speak. It's just a much less sophisticated method of achieving the same results, and very much **Slackware ARM specific**. 
  
 When I was looking into creating a local Slackware ARM mirror, most of the currently available scripts and software to perform this task was just way too advanced and extensive for my needs with regards to Slackware "//repodemia//". Something much more basic and bespoke was preferable, and that's the main reason why this script was created. When I was looking into creating a local Slackware ARM mirror, most of the currently available scripts and software to perform this task was just way too advanced and extensive for my needs with regards to Slackware "//repodemia//". Something much more basic and bespoke was preferable, and that's the main reason why this script was created.
  
-The script featured here, 'local-slackwarearm-repo.sh' [nickname: 'SAREPO'] does not attempt to supplant or undermine these (or other) contemporary efforts, by //re-inventing the wheel//, so to speak. It's just a much less sophisticated method of achieving the same results, and very much **Slackware ARM specific**. +
 ===== Question & Answer ===== ===== Question & Answer =====
  
Line 59: Line 61:
 # Create Slackware ARM local repository mirror utility script. # Create Slackware ARM local repository mirror utility script.
 # #
-# local-slackwarearm-repo.sh - SAREPO [v2.0.3]+# local-slackwarearm-repo.sh - SAREPO [v2.0.3] -  13 Mar 2021
 # #
-# Exaga - exaga@fatdog.eu - SARPi Project - 13 Mar 2021+Copyright (c) 2021 Exaga - SARPi Project - sarpi.penthux.net
 # #
 # Version - 08 Mar 2021 [v0.1a] - progenitor # Version - 08 Mar 2021 [v0.1a] - progenitor
Line 231: Line 233:
   cd "${SOURCEDIR}"   cd "${SOURCEDIR}"
   echo "${PETNAM} : verifying ${PRGNAM}.database ..."   echo "${PETNAM} : verifying ${PRGNAM}.database ..."
-  find . -type f ! -name "index.html" -exec ls -la --time-style=full "{}" >> "${TMP_DATA_DB}" \; +  find . -type f ! -name "index.html" -print0 | xargs -0 ls -la --time-style=full >> "${TMP_DATA_DB}"  
-  cmp -s "${TMP_DATA_DB}" "${LOCAL_SAREPO_DB}"   +  cmp -s "${TMP_DATA_DB}" "${LOCAL_SAREPO_DB}" && CMPSTATUS=0 || CMPSTATUS=1 
-  if [[ $-eq 0 ]]; then  +  if [[ $CMPSTATUS -eq 0 ]]; then  
-    log "${PETNAM} : Local repository database is up-to-date ... "+    log "${PETNAM} : Local repository database is up-to-date ..."
   else    else 
     rm -f "${LOCAL_SAREPO_DB}" && mv "${TMP_DATA_DB}" "${LOCAL_SAREPO_DB}" && log "${PETNAM} : [!] Local repository database updated!"     rm -f "${LOCAL_SAREPO_DB}" && mv "${TMP_DATA_DB}" "${LOCAL_SAREPO_DB}" && log "${PETNAM} : [!] Local repository database updated!"
   fi   fi
   log "${PETNAM} : local repository audit complete"     log "${PETNAM} : local repository audit complete"  
-  log "+-----------------------------------------------+"+  log "+-----------------------------------------------+" && echo >> ${LOG_FILE}
   echo "${PETNAM} update complete"   echo "${PETNAM} update complete"
   # Done   # Done
 howtos:hardware:arm:slackwarearm_local-mirror-repository ()