streamlets: support also weird paths with spaces (RELPIPE_IN_FILESYSTEM_STREAMLET_PATH)
--- a/streamlet-examples/cloc Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/cloc Sun Jan 19 18:00:31 2020 +0100
@@ -25,7 +25,7 @@
# Optional prefix can be added to attribute names: --option 'prefix' 'my_prefix_'
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
clocFields=()
--- a/streamlet-examples/exiftool Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/exiftool Sun Jan 19 18:00:31 2020 +0100
@@ -25,7 +25,7 @@
# - "available_attributes" – list of available attributes (each file may have different) separated by line-breaks (TODO: return as an array of strings, when this data type is implemented)
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
streamletFields=()
--- a/streamlet-examples/exiv2 Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/exiv2 Sun Jan 19 18:00:31 2020 +0100
@@ -23,7 +23,7 @@
# Two additional attributes are provided by this streamlet: "Image height" and "Image width" (they are extracted from "Image size").
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
streamletFields=()
--- a/streamlet-examples/hash Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/hash Sun Jan 19 18:00:31 2020 +0100
@@ -30,7 +30,7 @@
# --scriptlet hash --option "sha1" --as "sha1" --option "sha256" --as "sha256"
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
hashTypes=()
--- a/streamlet-examples/inode Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/inode Sun Jan 19 18:00:31 2020 +0100
@@ -19,7 +19,7 @@
# This streamlet provides a single attribute: inode number of given file
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
send OUTPUT_ATTRIBUTE_METADATA "${outputAttributeAliases[0]-inode}" "integer"
--- a/streamlet-examples/lines_count Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/lines_count Sun Jan 19 18:00:31 2020 +0100
@@ -21,7 +21,7 @@
# Directories are reported a 0 lines and with a null flag (will be supported in further Relational pipes versions).
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
send OUTPUT_ATTRIBUTE_METADATA "${outputAttributeAliases[0]-lines_count}" "integer"
--- a/streamlet-examples/mime_type Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/mime_type Sun Jan 19 18:00:31 2020 +0100
@@ -20,7 +20,7 @@
# It calls the tool file.
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
send OUTPUT_ATTRIBUTE_METADATA "${outputAttributeAliases[0]-mime_type}" "string"
--- a/streamlet-examples/pdfinfo Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/pdfinfo Sun Jan 19 18:00:31 2020 +0100
@@ -22,7 +22,7 @@
# List of available attributes can be obtained by directly calling the pdfinfo command on a PDF file.
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
pdfFields=()
--- a/streamlet-examples/pdftotext Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/pdftotext Sun Jan 19 18:00:31 2020 +0100
@@ -20,7 +20,7 @@
# n.b. the plain text content must fit into memory and shell variable and command-line argument (it usually will)
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
send OUTPUT_ATTRIBUTE_METADATA "${outputAttributeAliases[0]-pdftotext}" "string"
--- a/streamlet-examples/tesseract Sun Jan 19 17:05:46 2020 +0100
+++ b/streamlet-examples/tesseract Sun Jan 19 18:00:31 2020 +0100
@@ -20,7 +20,7 @@
# Languages can be specified by: --option "language" "eng" --option "language" "ces"
-. "$(dirname $0)/streamlet-common.sh"
+. "$(dirname "$0")/streamlet-common.sh"
processMessage_WAITING_FOR_OUTPUT_ATTRIBUTES_METADATA() {
tesseractLanguage="";