Commit db891b8b authored by Roque's avatar Roque

new ebulk command to get ebulk configuration info

parent 34ccf56f
......@@ -265,6 +265,21 @@ function defaultDataLakeUrl {
echo "[INFO] Data-lake url set to default '$DEFAULT_DATA_LAKE_URL'"
}
function displayInfo {
echo "[INFO] Current ebulk data-lake url: $DOWN_URL"
if [ -f "$CREDENTIALS_FILE" ]; then
STORED_CRED=$(cat "$CREDENTIALS_FILE" 2>/dev/null)
if [[ "$STORED_CRED" != "" ]]; then
IFS=';'
read -ra CRED_ARRAY <<< "$STORED_CRED"
echo "[INFO] Credentials stored for user: ${CRED_ARRAY[0]}"
IFS=' '
exit
fi
fi
echo "[INFO] No stored credentials."
}
function updateConfigFile {
if [ "$STORAGE" != "" ] ; then
echo
......@@ -664,6 +679,9 @@ while [ "$1" != "" ]; do
-v | --version ) echo "ebulk $EBULK_VERSION"
exit
;;
-i | --info ) displayInfo
exit
;;
-e | --examples ) cat $TOOL_PATH/example.md
exit
;;
......
......@@ -17,6 +17,7 @@ commands:
-r, --readme Opens README file
-e, --examples Shows some tool usage examples
-v, --version Ebulk tool version
-i, --info Displays information about datalake url, credentials, etc.
store-credentials Stores user and password for automatic authentication
set-data-lake-url Sets the data lake url where to ingest/download
default-data-lake-url Sets the data lake url to default
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment