Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env bash
- if [ $# -ne 1 ]; then
- echo "Usage: $0 <host>"
- exit 1
- fi
- echo "magic gremlin cli"
- while read -p "> " -r line; do
- if [ "$line" = "quit" ]; then
- exit 0
- else
- curl -X POST -d "{\"gremlin\":\"$line\"}" http://$1:8182/gremlin
- fi
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement