]> gitweb.fluxo.info Git - scripts.git/commitdiff
Fix: copy-item-to-kobo: check if item has unspported chars in it's file name
authorSilvio Rhatto <rhatto@riseup.net>
Tue, 30 Apr 2024 01:18:38 +0000 (22:18 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Tue, 30 Apr 2024 01:18:38 +0000 (22:18 -0300)
copy-item-to-kobo

index 0650a527cdcee6e20a94345feb6a8389dd3b4087..aa751fb3c2cada29c01044e2035fabe5399db277 100755 (executable)
@@ -33,6 +33,13 @@ fi
 show --search "$PATTERN" | while read item; do
   dirname="`dirname "$item"`"
 
+  # Check if item has unspported chars in it's file name
+  if echo "$item" | grep -q ':'; then
+    echo "$BASENAME: unsupported character ':' in file name '$item'"
+    echo "$BASENAME: please rename the file and try again"
+    exit 1
+  fi
+
   echo "Copying $item..."
 
   silentSsh $REMOTE <<EOC