@basictech/cli 0.0.24 → 0.0.25
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/commands/account.js +3 -3
- package/dist/commands/debug.js +1 -1
- package/dist/commands/init.js +6 -6
- package/dist/commands/login.js +3 -3
- package/dist/commands/logout.js +1 -1
- package/dist/commands/projects.js +6 -6
- package/dist/commands/pull.js +6 -6
- package/dist/commands/push.js +6 -6
- package/dist/commands/status.js +6 -6
- package/dist/commands/teams.js +7 -7
- package/dist/commands/update.js +4 -4
- package/dist/commands/version.js +2 -2
- package/dist/components/InitForm.js +5 -5
- package/dist/components/TeamForm.js +2 -2
- package/dist/index.js +12 -12
- package/dist/index.js.map +1 -1
- package/dist/lib/api.js +3 -3
- package/dist/lib/auth.js +3 -3
- package/package.json +3 -2
package/dist/commands/account.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { AuthService } from '../lib/auth';
|
|
2
|
-
import { isOnline } from '../lib/platform';
|
|
3
|
-
import { MESSAGES } from '../lib/constants';
|
|
1
|
+
import { AuthService } from '../lib/auth.js';
|
|
2
|
+
import { isOnline } from '../lib/platform.js';
|
|
3
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
4
4
|
export async function AccountCommand() {
|
|
5
5
|
// Check if online
|
|
6
6
|
if (!(await isOnline())) {
|
package/dist/commands/debug.js
CHANGED
package/dist/commands/init.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { render, Box, Text } from 'ink';
|
|
4
|
-
import { InitForm } from '../components/InitForm';
|
|
5
|
-
import { Spinner } from '../components/Spinner';
|
|
6
|
-
import { AuthService } from '../lib/auth';
|
|
7
|
-
import { checkForExistingConfig, readExistingConfig } from '../lib/config-templates';
|
|
8
|
-
import { isOnline } from '../lib/platform';
|
|
9
|
-
import { MESSAGES } from '../lib/constants';
|
|
4
|
+
import { InitForm } from '../components/InitForm.js';
|
|
5
|
+
import { Spinner } from '../components/Spinner.js';
|
|
6
|
+
import { AuthService } from '../lib/auth.js';
|
|
7
|
+
import { checkForExistingConfig, readExistingConfig } from '../lib/config-templates.js';
|
|
8
|
+
import { isOnline } from '../lib/platform.js';
|
|
9
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
10
10
|
function InitApp({ options }) {
|
|
11
11
|
const [state, setState] = React.useState({
|
|
12
12
|
loading: true,
|
package/dist/commands/login.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { AuthService } from '../lib/auth';
|
|
2
|
-
import { isOnline } from '../lib/platform';
|
|
3
|
-
import { MESSAGES } from '../lib/constants';
|
|
1
|
+
import { AuthService } from '../lib/auth.js';
|
|
2
|
+
import { isOnline } from '../lib/platform.js';
|
|
3
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
4
4
|
export async function LoginCommand() {
|
|
5
5
|
// Check if online
|
|
6
6
|
if (!(await isOnline())) {
|
package/dist/commands/logout.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { render, Text } from 'ink';
|
|
4
|
-
import { Table } from '../components/Table';
|
|
5
|
-
import { Spinner } from '../components/Spinner';
|
|
6
|
-
import { ApiClient } from '../lib/api';
|
|
7
|
-
import { AuthService } from '../lib/auth';
|
|
8
|
-
import { isOnline, openBrowser, copyToClipboard } from '../lib/platform';
|
|
9
|
-
import { MESSAGES } from '../lib/constants';
|
|
4
|
+
import { Table } from '../components/Table.js';
|
|
5
|
+
import { Spinner } from '../components/Spinner.js';
|
|
6
|
+
import { ApiClient } from '../lib/api.js';
|
|
7
|
+
import { AuthService } from '../lib/auth.js';
|
|
8
|
+
import { isOnline, openBrowser, copyToClipboard } from '../lib/platform.js';
|
|
9
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
10
10
|
function ProjectsApp() {
|
|
11
11
|
const [state, setState] = React.useState({
|
|
12
12
|
loading: true,
|
package/dist/commands/pull.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { render, Box, Text, useInput } from 'ink';
|
|
4
|
-
import { Spinner } from '../components/Spinner';
|
|
5
|
-
import { ApiClient } from '../lib/api';
|
|
6
|
-
import { AuthService } from '../lib/auth';
|
|
7
|
-
import { readSchemaFromConfig, compareVersions, saveSchemaToConfig } from '../lib/schema';
|
|
8
|
-
import { isOnline } from '../lib/platform';
|
|
9
|
-
import { MESSAGES } from '../lib/constants';
|
|
4
|
+
import { Spinner } from '../components/Spinner.js';
|
|
5
|
+
import { ApiClient } from '../lib/api.js';
|
|
6
|
+
import { AuthService } from '../lib/auth.js';
|
|
7
|
+
import { readSchemaFromConfig, compareVersions, saveSchemaToConfig } from '../lib/schema.js';
|
|
8
|
+
import { isOnline } from '../lib/platform.js';
|
|
9
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
10
10
|
function PullApp() {
|
|
11
11
|
const [state, setState] = React.useState({
|
|
12
12
|
phase: 'checking',
|
package/dist/commands/push.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { render, Box, Text, useInput } from 'ink';
|
|
4
|
-
import { Spinner } from '../components/Spinner';
|
|
5
|
-
import { ApiClient } from '../lib/api';
|
|
6
|
-
import { AuthService } from '../lib/auth';
|
|
7
|
-
import { readSchemaFromConfig, compareVersions } from '../lib/schema';
|
|
8
|
-
import { isOnline } from '../lib/platform';
|
|
9
|
-
import { MESSAGES } from '../lib/constants';
|
|
4
|
+
import { Spinner } from '../components/Spinner.js';
|
|
5
|
+
import { ApiClient } from '../lib/api.js';
|
|
6
|
+
import { AuthService } from '../lib/auth.js';
|
|
7
|
+
import { readSchemaFromConfig, compareVersions } from '../lib/schema.js';
|
|
8
|
+
import { isOnline } from '../lib/platform.js';
|
|
9
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
10
10
|
function PushApp() {
|
|
11
11
|
const [state, setState] = React.useState({
|
|
12
12
|
phase: 'checking',
|
package/dist/commands/status.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { render, Box, Text } from 'ink';
|
|
4
|
-
import { Spinner } from '../components/Spinner';
|
|
5
|
-
import { ApiClient } from '../lib/api';
|
|
6
|
-
import { AuthService } from '../lib/auth';
|
|
7
|
-
import { readSchemaFromConfig, compareVersions } from '../lib/schema';
|
|
8
|
-
import { isOnline } from '../lib/platform';
|
|
9
|
-
import { MESSAGES } from '../lib/constants';
|
|
4
|
+
import { Spinner } from '../components/Spinner.js';
|
|
5
|
+
import { ApiClient } from '../lib/api.js';
|
|
6
|
+
import { AuthService } from '../lib/auth.js';
|
|
7
|
+
import { readSchemaFromConfig, compareVersions } from '../lib/schema.js';
|
|
8
|
+
import { isOnline } from '../lib/platform.js';
|
|
9
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
10
10
|
function StatusApp() {
|
|
11
11
|
const [state, setState] = React.useState({
|
|
12
12
|
loading: true,
|
package/dist/commands/teams.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { render, Box, Text } from 'ink';
|
|
4
|
-
import { Table } from '../components/Table';
|
|
5
|
-
import { Spinner } from '../components/Spinner';
|
|
6
|
-
import { TeamForm } from '../components/TeamForm';
|
|
7
|
-
import { ApiClient } from '../lib/api';
|
|
8
|
-
import { AuthService } from '../lib/auth';
|
|
9
|
-
import { isOnline, openBrowser, copyToClipboard } from '../lib/platform';
|
|
10
|
-
import { MESSAGES } from '../lib/constants';
|
|
4
|
+
import { Table } from '../components/Table.js';
|
|
5
|
+
import { Spinner } from '../components/Spinner.js';
|
|
6
|
+
import { TeamForm } from '../components/TeamForm.js';
|
|
7
|
+
import { ApiClient } from '../lib/api.js';
|
|
8
|
+
import { AuthService } from '../lib/auth.js';
|
|
9
|
+
import { isOnline, openBrowser, copyToClipboard } from '../lib/platform.js';
|
|
10
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
11
11
|
function TeamsApp() {
|
|
12
12
|
const [state, setState] = React.useState({
|
|
13
13
|
loading: true,
|
package/dist/commands/update.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { spawn } from 'child_process';
|
|
2
|
-
import { getVersion } from '../lib/version';
|
|
3
|
-
import { ApiClient } from '../lib/api';
|
|
4
|
-
import { isOnline } from '../lib/platform';
|
|
5
|
-
import { MESSAGES } from '../lib/constants';
|
|
2
|
+
import { getVersion } from '../lib/version.js';
|
|
3
|
+
import { ApiClient } from '../lib/api.js';
|
|
4
|
+
import { isOnline } from '../lib/platform.js';
|
|
5
|
+
import { MESSAGES } from '../lib/constants.js';
|
|
6
6
|
export async function UpdateCommand() {
|
|
7
7
|
try {
|
|
8
8
|
// Check if online
|
package/dist/commands/version.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { getVersion } from '../lib/version';
|
|
2
|
-
import { ApiClient } from '../lib/api';
|
|
1
|
+
import { getVersion } from '../lib/version.js';
|
|
2
|
+
import { ApiClient } from '../lib/api.js';
|
|
3
3
|
export async function VersionCommand() {
|
|
4
4
|
const currentVersion = getVersion();
|
|
5
5
|
console.log(`basic-cli version ${currentVersion}`);
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { useState, useEffect } from 'react';
|
|
3
3
|
import { Box, Text, useInput } from 'ink';
|
|
4
|
-
import { ApiClient } from '../lib/api';
|
|
5
|
-
import { generateSlug } from '../lib/platform';
|
|
6
|
-
import { CONFIG_TEMPLATES } from '../lib/config-templates';
|
|
7
|
-
import { Spinner } from './Spinner';
|
|
8
|
-
import { TeamForm } from './TeamForm';
|
|
4
|
+
import { ApiClient } from '../lib/api.js';
|
|
5
|
+
import { generateSlug } from '../lib/platform.js';
|
|
6
|
+
import { CONFIG_TEMPLATES } from '../lib/config-templates.js';
|
|
7
|
+
import { Spinner } from './Spinner.js';
|
|
8
|
+
import { TeamForm } from './TeamForm.js';
|
|
9
9
|
export function InitForm({ onSuccess, onCancel, initialData }) {
|
|
10
10
|
const [state, setState] = useState({
|
|
11
11
|
step: initialData?.source ? (initialData.source === 'new' ? 'project-details' : 'existing-selection') : 'source',
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useState, useEffect } from 'react';
|
|
3
3
|
import { Box, Text, useInput } from 'ink';
|
|
4
|
-
import { ApiClient } from '../lib/api';
|
|
5
|
-
import { generateSlug } from '../lib/platform';
|
|
4
|
+
import { ApiClient } from '../lib/api.js';
|
|
5
|
+
import { generateSlug } from '../lib/platform.js';
|
|
6
6
|
export function TeamForm({ title, onSubmit, onCancel }) {
|
|
7
7
|
const [state, setState] = useState({
|
|
8
8
|
teamName: '',
|
package/dist/index.js
CHANGED
|
@@ -24,7 +24,7 @@ program
|
|
|
24
24
|
.description('Login to your Basic account')
|
|
25
25
|
.action(async () => {
|
|
26
26
|
try {
|
|
27
|
-
const { LoginCommand } = await import('./commands/login');
|
|
27
|
+
const { LoginCommand } = await import('./commands/login.js');
|
|
28
28
|
await LoginCommand();
|
|
29
29
|
process.exit(0);
|
|
30
30
|
}
|
|
@@ -40,7 +40,7 @@ program
|
|
|
40
40
|
.description('Logout from your Basic account')
|
|
41
41
|
.action(async () => {
|
|
42
42
|
try {
|
|
43
|
-
const { LogoutCommand } = await import('./commands/logout');
|
|
43
|
+
const { LogoutCommand } = await import('./commands/logout.js');
|
|
44
44
|
await LogoutCommand();
|
|
45
45
|
process.exit(0);
|
|
46
46
|
}
|
|
@@ -56,7 +56,7 @@ program
|
|
|
56
56
|
.description('Show account information')
|
|
57
57
|
.action(async () => {
|
|
58
58
|
try {
|
|
59
|
-
const { AccountCommand } = await import('./commands/account');
|
|
59
|
+
const { AccountCommand } = await import('./commands/account.js');
|
|
60
60
|
await AccountCommand();
|
|
61
61
|
process.exit(0);
|
|
62
62
|
}
|
|
@@ -72,7 +72,7 @@ program
|
|
|
72
72
|
.description('Show CLI version')
|
|
73
73
|
.action(async () => {
|
|
74
74
|
try {
|
|
75
|
-
const { VersionCommand } = await import('./commands/version');
|
|
75
|
+
const { VersionCommand } = await import('./commands/version.js');
|
|
76
76
|
await VersionCommand();
|
|
77
77
|
process.exit(0);
|
|
78
78
|
}
|
|
@@ -88,7 +88,7 @@ program
|
|
|
88
88
|
.description('Update CLI to the latest version')
|
|
89
89
|
.action(async () => {
|
|
90
90
|
try {
|
|
91
|
-
const { UpdateCommand } = await import('./commands/update');
|
|
91
|
+
const { UpdateCommand } = await import('./commands/update.js');
|
|
92
92
|
await UpdateCommand();
|
|
93
93
|
process.exit(0);
|
|
94
94
|
}
|
|
@@ -111,7 +111,7 @@ program
|
|
|
111
111
|
.description('Show Basic config directory location')
|
|
112
112
|
.action(async () => {
|
|
113
113
|
try {
|
|
114
|
-
const { DebugCommand } = await import('./commands/debug');
|
|
114
|
+
const { DebugCommand } = await import('./commands/debug.js');
|
|
115
115
|
await DebugCommand();
|
|
116
116
|
process.exit(0);
|
|
117
117
|
}
|
|
@@ -127,7 +127,7 @@ program
|
|
|
127
127
|
.description('List and browse your projects')
|
|
128
128
|
.action(async () => {
|
|
129
129
|
try {
|
|
130
|
-
const { ProjectsCommand } = await import('./commands/projects');
|
|
130
|
+
const { ProjectsCommand } = await import('./commands/projects.js');
|
|
131
131
|
await ProjectsCommand();
|
|
132
132
|
}
|
|
133
133
|
catch (error) {
|
|
@@ -143,7 +143,7 @@ program
|
|
|
143
143
|
.description('List teams or create a new team')
|
|
144
144
|
.action(async (action) => {
|
|
145
145
|
try {
|
|
146
|
-
const { TeamsCommand } = await import('./commands/teams');
|
|
146
|
+
const { TeamsCommand } = await import('./commands/teams.js');
|
|
147
147
|
await TeamsCommand(action);
|
|
148
148
|
}
|
|
149
149
|
catch (error) {
|
|
@@ -158,7 +158,7 @@ program
|
|
|
158
158
|
.description('Show project status')
|
|
159
159
|
.action(async () => {
|
|
160
160
|
try {
|
|
161
|
-
const { StatusCommand } = await import('./commands/status');
|
|
161
|
+
const { StatusCommand } = await import('./commands/status.js');
|
|
162
162
|
await StatusCommand();
|
|
163
163
|
}
|
|
164
164
|
catch (error) {
|
|
@@ -173,7 +173,7 @@ program
|
|
|
173
173
|
.description('Pull schema from remote')
|
|
174
174
|
.action(async () => {
|
|
175
175
|
try {
|
|
176
|
-
const { PullCommand } = await import('./commands/pull');
|
|
176
|
+
const { PullCommand } = await import('./commands/pull.js');
|
|
177
177
|
await PullCommand();
|
|
178
178
|
}
|
|
179
179
|
catch (error) {
|
|
@@ -188,7 +188,7 @@ program
|
|
|
188
188
|
.description('Push schema to remote')
|
|
189
189
|
.action(async () => {
|
|
190
190
|
try {
|
|
191
|
-
const { PushCommand } = await import('./commands/push');
|
|
191
|
+
const { PushCommand } = await import('./commands/push.js');
|
|
192
192
|
await PushCommand();
|
|
193
193
|
}
|
|
194
194
|
catch (error) {
|
|
@@ -209,7 +209,7 @@ program
|
|
|
209
209
|
.option('--js', 'Use JavaScript configuration template')
|
|
210
210
|
.action(async (options) => {
|
|
211
211
|
try {
|
|
212
|
-
const { InitCommand } = await import('./commands/init');
|
|
212
|
+
const { InitCommand } = await import('./commands/init.js');
|
|
213
213
|
await InitCommand(options);
|
|
214
214
|
}
|
|
215
215
|
catch (error) {
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAa,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAExD,+BAA+B;AAC/B,OAAO,CAAC,EAAE,CAAC,mBAAmB,EAAE,CAAC,KAAK,EAAE,EAAE;IACxC,OAAO,CAAC,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;IAC7C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC;AAEH,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;IACxB,OAAO,CAAC,GAAG,CAAC,uBAAuB,CAAC,CAAC;IACrC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC;AAEH,oBAAoB;AACpB,OAAO;KACJ,IAAI,CAAC,OAAO,CAAC;KACb,WAAW,CAAC,iDAAiD,CAAC;KAC9D,OAAO,CAAC,UAAU,EAAE,CAAC,CAAC;AAEzB,gBAAgB;AAChB,OAAO;KACJ,OAAO,CAAC,OAAO,CAAC;KAChB,WAAW,CAAC,6BAA6B,CAAC;KAC1C,MAAM,CAAC,KAAK,IAAI,EAAE;IACjB,IAAI,CAAC;QACH,MAAM,EAAE,YAAY,EAAE,GAAG,MAAM,MAAM,CAAC,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAa,QAAQ,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AC,QAAQ,CAAC,CAAC,CAAC;QACrC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC,CAAC,CAAC;AAEL,0BAA0B;AAC1B,OAAO,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC,QAAQ,EAAE,EAAE;IACnC,MAAM,cAAc,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;IACnC,MAAM,WAAW,GAAG,mBAAmB,CAAC,cAAc,CAAC,CAAC;IAExD,OAAO,CAAC,KAAK,CAAC,oBAAoB,cAAc,IAAI,CAAC,CAAC;IAEtD,IAAI,WAAW,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC3B,OAAO,CAAC,KAAK,CAAC,eAAe,CAAC,CAAC;QAC/B,WAAW,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE;YAC/B,OAAO,CAAC,KAAK,CAAC,OAAO,UAAU,EAAE,CAAC,CAAC;QACrC,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;IACpB,CAAC;IAED,OAAO,CAAC,KAAK,CAAC,uCAAuC,CAAC,CAAC;IACvD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC;AAEH,8CAA8C;AAC9C,IAAI,OAAO,CAAC,IAAI,CAAC,MAAM,IAAI,CAAC,EAAE,CAAC;IAC7B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;IAC9B,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC;AAED,+BAA+B;AAC/B,OAAO,CAAC,KAAK,EAAE,CAAC"}
|
package/dist/lib/api.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { CONSTANTS } from './constants';
|
|
2
|
-
import { AuthService } from './auth';
|
|
3
|
-
import { ApiError, handleError } from './errors';
|
|
1
|
+
import { CONSTANTS } from './constants.js';
|
|
2
|
+
import { AuthService } from './auth.js';
|
|
3
|
+
import { ApiError, handleError } from './errors.js';
|
|
4
4
|
export class ApiClient {
|
|
5
5
|
static instance;
|
|
6
6
|
authService;
|
package/dist/lib/auth.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createServer } from 'http';
|
|
2
2
|
import { promises as fs } from 'fs';
|
|
3
|
-
import { CONSTANTS } from './constants';
|
|
4
|
-
import { getConfigPath, getConfigDir, openBrowser } from './platform';
|
|
5
|
-
import { AuthError, handleError } from './errors';
|
|
3
|
+
import { CONSTANTS } from './constants.js';
|
|
4
|
+
import { getConfigPath, getConfigDir, openBrowser } from './platform.js';
|
|
5
|
+
import { AuthError, handleError } from './errors.js';
|
|
6
6
|
export class AuthService {
|
|
7
7
|
static instance;
|
|
8
8
|
static getInstance() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@basictech/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.25",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Basic CLI for creating & managing your projects",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"basic": "dist/index.js"
|
|
9
9
|
},
|
|
10
10
|
"scripts": {
|
|
11
|
-
"build": "tsc",
|
|
11
|
+
"build": "tsc && node -e \"const fs = require('fs'); const path = require('path'); function fixImports(dir) { const files = fs.readdirSync(dir); files.forEach(file => { const filePath = path.join(dir, file); const stat = fs.statSync(filePath); if (stat.isDirectory()) { fixImports(filePath); } else if (file.endsWith('.js')) { let content = fs.readFileSync(filePath, 'utf8'); content = content.replace(/from\\s+['\\\"]\\.\\.?\\/([^'\\\"]*)['\\\"];/g, (match, p1) => { if (p1.includes('.')) return match; return match.replace(p1, p1 + '.js'); }); fs.writeFileSync(filePath, content); } }); } fixImports('dist');\"",
|
|
12
12
|
"dev": "tsx src/index.ts",
|
|
13
13
|
"dev:watch": "tsx watch src/index.ts",
|
|
14
14
|
"test": "vitest run --exclude='tests/components/**'",
|
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
"ink-testing-library": "^4.0.0",
|
|
38
38
|
"tsx": "^4.19.2",
|
|
39
39
|
"typescript": "^5.6.3",
|
|
40
|
+
"vite": "^6.3.5",
|
|
40
41
|
"vitest": "^1.6.1"
|
|
41
42
|
},
|
|
42
43
|
"files": [
|