qingstor / qsctl

Advanced command line tool for QingStor Object Storage.
Apache License 2.0
23 stars 13 forks source link

Interactive setup may cause bugs when used with pipe in scripts #290

Closed Prnyself closed 4 years ago

Prnyself commented 4 years ago
#!/bin/bash

set -e
set -o pipefail

unset LANGUAGE
unset LANG
unset LC_ALL

qsctl --debug --config=/root/.qingstor/config.yaml cat qs://snapshot/by/ss-bytvqkwx.img.lz4 > /tmp/1

When config file not existed, Interactive setup will run and it may cause error because of some characters e.g. \n, \r

Prnyself commented 4 years ago

close by #292