mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-21 18:37:45 +08:00
It looks like there were two problems: - "read" command probably needs the name of the variable it reads into - [[ didn't work This might be because on Linux /bin/sh is sometimes not bash. For example on Ubuntu it is a symlink to dash. License: MIT Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
14 lines
223 B
Bash
Executable File
14 lines
223 B
Bash
Executable File
#!/bin/sh
|
|
# Author: Juan Batiz-Benet <juan@benet.ai>
|
|
# MIT LICENSED
|
|
|
|
# if not a terminal, exit 0 (yes!)
|
|
test -t 1 || exit 0
|
|
|
|
read -p "continue? [y/N] " REPLY
|
|
echo
|
|
case "$REPLY" in
|
|
[Yy]*) exit 0 ;;
|
|
*) exit 1 ;;
|
|
esac
|