@intella/cli 0.0.3 → 0.0.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/index.js +11 -7
- package/dist/index.js.map +3 -3
- package/package.json +4 -14
package/dist/index.js
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
// @bun
|
|
4
|
-
|
|
4
|
+
import { createRequire } from "node:module";
|
|
5
5
|
// Polyfill import.meta.require for Node.js compatibility
|
|
6
|
-
import { createRequire } from 'module';
|
|
7
6
|
if (typeof import.meta.require === 'undefined') {
|
|
8
7
|
const require = createRequire(import.meta.url);
|
|
9
8
|
Object.defineProperty(import.meta, 'require', {
|
|
@@ -13,7 +12,6 @@ if (typeof import.meta.require === 'undefined') {
|
|
|
13
12
|
});
|
|
14
13
|
}
|
|
15
14
|
|
|
16
|
-
import { createRequire } from "node:module";
|
|
17
15
|
var __create = Object.create;
|
|
18
16
|
var __getProtoOf = Object.getPrototypeOf;
|
|
19
17
|
var __defProp = Object.defineProperty;
|
|
@@ -50325,7 +50323,7 @@ async function standardizePrompt(prompt) {
|
|
|
50325
50323
|
function wrapGatewayError(error95) {
|
|
50326
50324
|
if (!GatewayAuthenticationError.isInstance(error95))
|
|
50327
50325
|
return error95;
|
|
50328
|
-
const isProductionEnv = (process == null ? undefined : "
|
|
50326
|
+
const isProductionEnv = (process == null ? undefined : "production") === "production";
|
|
50329
50327
|
const moreInfoURL = "https://ai-sdk.dev/unauthenticated-ai-gateway";
|
|
50330
50328
|
if (isProductionEnv) {
|
|
50331
50329
|
return new AISDKError3({
|
|
@@ -295900,7 +295898,7 @@ var require_dev_credentials = __commonJS((exports) => {
|
|
|
295900
295898
|
return auth;
|
|
295901
295899
|
}
|
|
295902
295900
|
function shouldPromptForCredentials() {
|
|
295903
|
-
return
|
|
295901
|
+
return false;
|
|
295904
295902
|
}
|
|
295905
295903
|
async function generateCredentials(opts) {
|
|
295906
295904
|
const { OAuth, pollForToken, getAuth, updateAuthConfig, inferScope } = await importAuth();
|
|
@@ -298269,11 +298267,17 @@ function initializeIntellaDirs() {
|
|
|
298269
298267
|
function initializeAuthDir() {
|
|
298270
298268
|
initializeIntellaDirs();
|
|
298271
298269
|
}
|
|
298270
|
+
function getEnv() {
|
|
298271
|
+
return "production";
|
|
298272
|
+
}
|
|
298272
298273
|
function getApiUrl() {
|
|
298273
298274
|
if (process.env.INTELLA_API_URL) {
|
|
298274
298275
|
return process.env.INTELLA_API_URL;
|
|
298275
298276
|
}
|
|
298276
|
-
|
|
298277
|
+
let isDev = getEnv() === "development";
|
|
298278
|
+
if (process.env.INTELLA_DEV === "true") {
|
|
298279
|
+
isDev = true;
|
|
298280
|
+
}
|
|
298277
298281
|
if (isDev) {
|
|
298278
298282
|
return "http://localhost:3004";
|
|
298279
298283
|
}
|
|
@@ -326581,4 +326585,4 @@ yargs_default(hideBin(process.argv)).scriptName("intella-cli").version("1.0.0").
|
|
|
326581
326585
|
await whoamiCommand();
|
|
326582
326586
|
}).demandCommand(1, "You need at least one command before moving on").help().alias("help", "h").alias("version", "v").strict().parse();
|
|
326583
326587
|
|
|
326584
|
-
//# debugId=
|
|
326588
|
+
//# debugId=20B8594E5F52196064756E2164756E21
|