@secondlayer/cli 5.1.3 → 5.1.5
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/dist/cli.js +35 -3
- package/dist/cli.js.map +3 -3
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -32443,7 +32443,7 @@ var {
|
|
|
32443
32443
|
// package.json
|
|
32444
32444
|
var package_default = {
|
|
32445
32445
|
name: "@secondlayer/cli",
|
|
32446
|
-
version: "5.1.
|
|
32446
|
+
version: "5.1.5",
|
|
32447
32447
|
description: "CLI for subgraphs and blockchain indexing on Stacks",
|
|
32448
32448
|
type: "module",
|
|
32449
32449
|
bin: {
|
|
@@ -34646,7 +34646,7 @@ async function runLoginFlow() {
|
|
|
34646
34646
|
expiresAt
|
|
34647
34647
|
});
|
|
34648
34648
|
success(`Logged in as ${verified.account.email}`);
|
|
34649
|
-
|
|
34649
|
+
await printPostLoginHints();
|
|
34650
34650
|
} catch (err) {
|
|
34651
34651
|
if (err instanceof CliHttpError) {
|
|
34652
34652
|
error(err.message);
|
|
@@ -34656,6 +34656,38 @@ async function runLoginFlow() {
|
|
|
34656
34656
|
process.exit(1);
|
|
34657
34657
|
}
|
|
34658
34658
|
}
|
|
34659
|
+
async function printPostLoginHints() {
|
|
34660
|
+
let hasTenant = false;
|
|
34661
|
+
try {
|
|
34662
|
+
const tenant = await httpPlatform("/api/tenants/me");
|
|
34663
|
+
hasTenant = Boolean(tenant.tenant?.apiUrl);
|
|
34664
|
+
} catch (err) {
|
|
34665
|
+
if (!(err instanceof CliHttpError && err.status === 404)) {
|
|
34666
|
+
info(dim("Run 'sl whoami' to see your account status."));
|
|
34667
|
+
return;
|
|
34668
|
+
}
|
|
34669
|
+
}
|
|
34670
|
+
if (hasTenant) {
|
|
34671
|
+
info(dim("Run 'sl whoami' to see your account status."));
|
|
34672
|
+
return;
|
|
34673
|
+
}
|
|
34674
|
+
console.log();
|
|
34675
|
+
info("First time? Here's the path to your first query:");
|
|
34676
|
+
console.log();
|
|
34677
|
+
console.log(dim(" 1. ") + cyan("sl project create my-app"));
|
|
34678
|
+
console.log(dim(" ") + dim("# scopes your data and routing — pick any name"));
|
|
34679
|
+
console.log();
|
|
34680
|
+
console.log(dim(" 2. ") + cyan("sl instance create --plan launch"));
|
|
34681
|
+
console.log(dim(" ") + dim("# $99/mo · 2 vCPU / 6GB · run `sl --help` for other plans"));
|
|
34682
|
+
console.log();
|
|
34683
|
+
console.log(dim(" 3. ") + cyan("sl subgraphs new my-watcher --template sip-010-balances"));
|
|
34684
|
+
console.log(dim(" ") + dim("# five templates ship with the CLI"));
|
|
34685
|
+
console.log();
|
|
34686
|
+
console.log(dim(" 4. ") + cyan("sl subgraphs deploy subgraphs/my-watcher.ts"));
|
|
34687
|
+
console.log(dim(" ") + dim("# six seconds, backfill auto-starts"));
|
|
34688
|
+
console.log();
|
|
34689
|
+
info(dim("Run `sl whoami` at any time to see where you are in the flow."));
|
|
34690
|
+
}
|
|
34659
34691
|
function registerLoginCommand(program2) {
|
|
34660
34692
|
program2.command("login").description("Log in to Secondlayer (magic-link email)").action(runLoginFlow);
|
|
34661
34693
|
}
|
|
@@ -37370,5 +37402,5 @@ registerAccountCommand(program);
|
|
|
37370
37402
|
registerBillingCommand(program);
|
|
37371
37403
|
program.parse();
|
|
37372
37404
|
|
|
37373
|
-
//# debugId=
|
|
37405
|
+
//# debugId=7BAF23F53752FABB64756E2164756E21
|
|
37374
37406
|
//# sourceMappingURL=cli.js.map
|