Skip to content

Commit

Permalink
feat(globals): removing globals and kit-internal
Browse files Browse the repository at this point in the history
  • Loading branch information
johnlindquist committed Dec 4, 2024
1 parent e685e29 commit 84936a4
Show file tree
Hide file tree
Showing 20 changed files with 178 additions and 140 deletions.
10 changes: 9 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@
}
},
"dependencies": {
"@johnlindquist/kit-internal": "^1.13.5",
"@johnlindquist/open": "^10.1.1",
"@octokit/auth-oauth-device": "7.1.1",
"@octokit/core": "6.1.2",
Expand All @@ -83,6 +82,7 @@
"@octokit/plugin-retry": "7.1.2",
"@octokit/plugin-throttling": "9.3.2",
"@types/chalk": "2.2.4",
"@types/date-fns": "2.6.3",
"@types/fs-extra": "11.0.4",
"@types/shelljs": "0.8.15",
"@typescript/lib-dom": "npm:@johnlindquist/no-dom@^1.0.2",
Expand All @@ -96,8 +96,11 @@
"chalk-template": "0.4.0",
"chrome-trace-event": "^1.0.4",
"color-name": "2.0.0",
"date-fns": "4.1.0",
"dotenv": "^16.4.5",
"dotenv-flow": "4.1.0",
"download": "8.0.0",
"enquirer": "2.4.1",
"esbuild": "0.24.0",
"execa": "9.5.1",
"filesize": "10.1.6",
Expand All @@ -109,14 +112,19 @@
"jsonfile": "6.1.0",
"keyv": "^5.2.1",
"keyv-file": "^5.0.3",
"lowdb": "7.0.1",
"marked": "4.3.0",
"minimist": "1.2.8",
"p-retry": "6.2.1",
"project-name-generator": "2.1.9",
"quick-score": "^0.2.0",
"replace-in-file": "8.2.0",
"rimraf": "6.0.1",
"rxjs": "7.8.1",
"safe-stable-stringify": "^2.5.0",
"shelljs": "0.8.5",
"slugify": "1.6.6",
"strip-ansi": "7.1.0",
"suggestion": "2.1.2",
"tmp-promise": "3.0.3",
"untildify": "5.0.0"
Expand Down
101 changes: 93 additions & 8 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/api/global.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import type { PromptConfig } from "../types/core"
import {
format,
formatDistanceToNow,
} from "@johnlindquist/kit-internal/date-fns"
} from "date-fns"
import { kitPnpmPath } from "../core/resolvers.js"

global.actionFlag = ""
Expand Down
8 changes: 4 additions & 4 deletions src/api/kit.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import path from "node:path"
import { existsSync, lstatSync } from "node:fs"
import {
readFile,
readJson,
} from "@johnlindquist/kit-internal/fs-extra"
} from "../globals/fs-extra.js"
import { readFile } from "../globals/fs.js"
import * as os from "node:os"
import { pathToFileURL } from "node:url"
import * as JSONSafe from "safe-stable-stringify"
Expand All @@ -14,7 +14,7 @@ import {
type Options,
type ConfigOptions,
} from "quick-score"
import { formatDistanceToNow } from "@johnlindquist/kit-internal/date-fns"
import { formatDistanceToNow } from "date-fns"
import type {
Action,
Choice,
Expand Down Expand Up @@ -53,7 +53,7 @@ import {
setUserJson,
} from "../core/db.js"

import { stripAnsi } from "@johnlindquist/kit-internal/strip-ansi"
import { default as stripAnsi } from "strip-ansi"

import type { Kenv } from "../types/kit"
import type { Fields as TraceFields } from "chrome-trace-event"
Expand Down
5 changes: 0 additions & 5 deletions src/cli/duplicate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ import {
stripMetadata,
uniq,
} from "../core/utils.js"
import { generate } from "@johnlindquist/kit-internal/project-name-generator"

let examples = Array.from({ length: 3 })
.map((_, i) => generate({ words: 2 }).dashed)
.join(", ")

let { filePath } = await selectScript(
"Select Script to Duplicate"
Expand Down
Loading

0 comments on commit 84936a4

Please sign in to comment.