tursodatabase / turso-install

Turso CLI installer
https://turso.tech
MIT License
1 stars 5 forks source link

Installing without browser experience is not great... #6

Open penberg opened 1 year ago

penberg commented 1 year ago
Installing to /home/penberg/.turso

Turso CLI installed!

If you are a new user, you can sign up with turso auth signup.

If you already have an account, please login with turso auth login.

/usr/bin/xdg-open: line 881: www-browser: command not found
/usr/bin/xdg-open: line 881: links2: command not found
/usr/bin/xdg-open: line 881: elinks: command not found
/usr/bin/xdg-open: line 881: links: command not found
/usr/bin/xdg-open: line 881: lynx: command not found
/usr/bin/xdg-open: line 881: w3m: command not found
xdg-open: no method available for opening 'https://api.turso.tech/signup?port=33341&redirect=true'
error: Unable to open browser.
Visit this URL on this device to log in:
https://api.turso.tech/signup?port=33341&redirect=true
Waiting for authentication...
hrutik7 commented 1 year ago

any update on this !

haaawk commented 1 year ago

What is the expected experience when a user has no browser?

tindecken commented 1 year ago

is there any workarround on it?

hrutik7 commented 1 year ago

use turso cli commands and if you are windows use wsl 22.x version

GV14982 commented 1 year ago

While it's not ideal, they have this in their docs: https://docs.turso.tech/reference/turso-cli#running-remotely

armandabric commented 11 months ago

The issue is that the turso auth signup is always run at the end of the install script. Even with a TURSO_API_TOKEN environment variable it's triggered.

https://github.com/tursodatabase/turso-install/blob/a154864fffcfd4e9550dd9fc08524c287c793dc3/install.sh#L154-L158

Given that the signup/login instruction are printed at the end of the installation, could we consider to remove the auto signup?

Right now I'm stuck, I was looking to install the turso CLI on github actions to create database for each PR.

teneburu commented 11 months ago

This problem got me as well.

penberg commented 10 months ago

The following pull request should improve the experience a bit once we roll out a new CLI release. https://github.com/tursodatabase/turso-cli/pull/737. I think what we could do is implement a turso auth whoami command and use that to skip the turso auth signup step in the script if we're logged in.

penberg commented 10 months ago

@armandabric There's now a TURSO_INSTALL_SKIP_SIGNUP environment variable that you can use to make the script skip the sign up part. Let us know if it works for your use case.