vibekit-auth 1.0.2 → 1.0.4
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/index.js +5 -1
- package/package.json +1 -1
- package/src/index.ts +17 -5
package/dist/index.js
CHANGED
|
@@ -44,7 +44,9 @@ async function main() {
|
|
|
44
44
|
extractSpinner.fail(chalk_1.default.red('Claude credentials have expired'));
|
|
45
45
|
console.log();
|
|
46
46
|
console.log(chalk_1.default.yellow(' Please re-authenticate with Claude Code:'));
|
|
47
|
-
console.log(chalk_1.default.gray(' Run:
|
|
47
|
+
console.log(chalk_1.default.gray(' 1. Run: security delete-generic-password -s "Claude Code-credentials"'));
|
|
48
|
+
console.log(chalk_1.default.gray(' 2. Run: claude'));
|
|
49
|
+
console.log(chalk_1.default.gray(' 3. Complete the login flow in your browser'));
|
|
48
50
|
console.log();
|
|
49
51
|
process.exit(1);
|
|
50
52
|
}
|
|
@@ -123,6 +125,8 @@ async function main() {
|
|
|
123
125
|
console.log(chalk_1.default.white(' Open Telegram and use /auto to start.'));
|
|
124
126
|
console.log(chalk_1.default.gray(' Your Claude subscription will be used for AI - no credits needed.'));
|
|
125
127
|
console.log();
|
|
128
|
+
console.log(chalk_1.default.dim(' You may now close this terminal.'));
|
|
129
|
+
console.log();
|
|
126
130
|
}
|
|
127
131
|
else {
|
|
128
132
|
uploadSpinner.fail(chalk_1.default.red('Upload failed'));
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -35,10 +35,12 @@ async function main() {
|
|
|
35
35
|
if (!credentials) {
|
|
36
36
|
extractSpinner.fail(chalk.red('Claude credentials not found'));
|
|
37
37
|
console.log();
|
|
38
|
-
console.log(chalk.yellow('
|
|
38
|
+
console.log(chalk.yellow(' Set up Claude Code with long-lived tokens (recommended):'));
|
|
39
39
|
console.log(chalk.gray(' 1. Install: npm install -g @anthropic-ai/claude-code'));
|
|
40
|
-
console.log(chalk.gray(' 2. Run: claude'));
|
|
41
|
-
console.log(chalk.gray(' 3.
|
|
40
|
+
console.log(chalk.gray(' 2. Run: claude setup-token'));
|
|
41
|
+
console.log(chalk.gray(' 3. Follow the prompts to authenticate'));
|
|
42
|
+
console.log();
|
|
43
|
+
console.log(chalk.gray(' This creates tokens valid for 1 year.'));
|
|
42
44
|
console.log();
|
|
43
45
|
process.exit(1);
|
|
44
46
|
}
|
|
@@ -49,8 +51,12 @@ async function main() {
|
|
|
49
51
|
if (expiry.expired) {
|
|
50
52
|
extractSpinner.fail(chalk.red('Claude credentials have expired'));
|
|
51
53
|
console.log();
|
|
52
|
-
console.log(chalk.yellow('
|
|
53
|
-
console.log(chalk.
|
|
54
|
+
console.log(chalk.yellow(' For long-lived tokens (1 year), run:'));
|
|
55
|
+
console.log(chalk.white(' claude setup-token'));
|
|
56
|
+
console.log();
|
|
57
|
+
console.log(chalk.gray(' Or for short-lived tokens, re-authenticate:'));
|
|
58
|
+
console.log(chalk.gray(' 1. Run: security delete-generic-password -s "Claude Code-credentials"'));
|
|
59
|
+
console.log(chalk.gray(' 2. Run: claude, then /login'));
|
|
54
60
|
console.log();
|
|
55
61
|
process.exit(1);
|
|
56
62
|
}
|
|
@@ -61,6 +67,10 @@ async function main() {
|
|
|
61
67
|
// Show expiry info
|
|
62
68
|
if (expiry.expiringSoon) {
|
|
63
69
|
console.log(chalk.yellow(` ⚠ Expires in ${expiry.daysUntilExpiry} days (${expiry.expiresAt.toLocaleDateString()})`));
|
|
70
|
+
console.log(chalk.gray(' Tip: Run `claude setup-token` for 1-year tokens'));
|
|
71
|
+
} else if (expiry.daysUntilExpiry < 30) {
|
|
72
|
+
console.log(chalk.gray(` Expires: ${expiry.expiresAt.toLocaleDateString()} (${expiry.daysUntilExpiry} days)`));
|
|
73
|
+
console.log(chalk.gray(' Tip: Run `claude setup-token` for 1-year tokens'));
|
|
64
74
|
} else {
|
|
65
75
|
console.log(chalk.gray(` Expires: ${expiry.expiresAt.toLocaleDateString()} (${expiry.daysUntilExpiry} days)`));
|
|
66
76
|
}
|
|
@@ -139,6 +149,8 @@ async function main() {
|
|
|
139
149
|
console.log(chalk.white(' Open Telegram and use /auto to start.'));
|
|
140
150
|
console.log(chalk.gray(' Your Claude subscription will be used for AI - no credits needed.'));
|
|
141
151
|
console.log();
|
|
152
|
+
console.log(chalk.dim(' You may now close this terminal.'));
|
|
153
|
+
console.log();
|
|
142
154
|
} else {
|
|
143
155
|
uploadSpinner.fail(chalk.red('Upload failed'));
|
|
144
156
|
console.log(chalk.red(` ${result.message}`));
|