mirror of
https://github.com/robbyrussell/oh-my-zsh.git
synced 2026-11-29 20:03:07 +01:00
fix(localstack): require message file argument in sqs-send (#14315)
This commit is contained in:
1 parent
ec7622cfbc
commit
f8277e5043
1 file changed
+3
-3
@@ -28,10 +28,10 @@ lsk() {
|
||||
# Example
|
||||
# sqs-send user user.json
|
||||
sqs-send(){
|
||||
if [ -z "$1" ]; then
|
||||
echo "Use: sqs-send <queue> <payload>"
|
||||
if [ -z "$1" ] || [ -z "$2" ]; then
|
||||
echo "Use: sqs-send <queue> <payload>" >&2
|
||||
return 1
|
||||
fi
|
||||
|
||||
curl -X POST "http://localhost:4566/000000000000/$1" -d "Action=SendMessage" -d "MessageBody=$(cat $2)"
|
||||
curl -X POST "http://localhost:4566/000000000000/$1" -d "Action=SendMessage" -d "MessageBody=$(cat "$2")"
|
||||
}
|
||||
Reference in new issue
Block a user