unoverse 0.1.50 → 0.1.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/operator/lib/ground.sh +8 -6
- package/package.json +1 -1
package/operator/lib/ground.sh
CHANGED
|
@@ -44,18 +44,20 @@ _ground_do() {
|
|
|
44
44
|
# so there is nothing to leave the flow for. The token comes from
|
|
45
45
|
# cloud.digitalocean.com/account/api (Generate New Token, read and write).
|
|
46
46
|
echo ""
|
|
47
|
-
|
|
47
|
+
# ONE prompt, ours. doctl auth init prints its own paragraph repeating the link,
|
|
48
|
+
# so the token is taken here and handed over silently (-t): one message, one paste.
|
|
49
|
+
info "A DigitalOcean API token connects your account. Generate one here:"
|
|
48
50
|
echo ""
|
|
49
51
|
echo -e " ${CYAN}https://cloud.digitalocean.com/account/api/tokens${NC}"
|
|
50
52
|
echo ""
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
if ! doctl account get >/dev/null 2>&1; then
|
|
53
|
+
local DO_TOKEN
|
|
54
|
+
read -r -s -p " Paste the token (hidden): " DO_TOKEN
|
|
55
|
+
echo ""
|
|
56
|
+
if [ -z "$DO_TOKEN" ] || ! doctl auth init -t "$DO_TOKEN" >/dev/null 2>&1 || ! doctl account get >/dev/null 2>&1; then
|
|
56
57
|
fail "that token did not authenticate"
|
|
57
58
|
return 1
|
|
58
59
|
fi
|
|
60
|
+
ok "DigitalOcean connected"
|
|
59
61
|
fi
|
|
60
62
|
ok "doctl authenticated"
|
|
61
63
|
|
package/package.json
CHANGED