Skip to content

Commit 816749e

Browse files
committed
refactor(preflight): remove unused cli-ai from preflight downloads
cli-ai is not currently used, so remove it from background preflight downloads. Final download order: coana → cdxgen → Python → socketsecurity. Also consolidates .gitignore workspace entries into root .gitignore to reduce duplication across package-level ignores.
1 parent 59c38ad commit 816749e

File tree

5 files changed

+15
-25
lines changed

5 files changed

+15
-25
lines changed

.gitignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,15 @@ packages/*/.yoga-tests
5959
packages/*/.onnx-source
6060
packages/*/.minilm-source
6161
**/html
62+
63+
# Workspace ignores
64+
packages/cli/CHANGELOG.md
65+
packages/cli/LICENSE
66+
packages/cli/*.png
67+
packages/cli-with-sentry/data/
68+
packages/cli-with-sentry/CHANGELOG.md
69+
packages/cli-with-sentry/LICENSE
70+
packages/cli-with-sentry/*.png
71+
packages/socket/CHANGELOG.md
72+
packages/socket/LICENSE
73+
packages/socket/*.png
Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,2 @@
11
/coverage
2-
/data
32
**/dist
4-
CHANGELOG.md
5-
LICENSE
6-
*.png

packages/cli/.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
11
/coverage
22
**/dist
3-
CHANGELOG.md
4-
LICENSE
5-
*.png

packages/cli/src/utils/preflight/downloads.mts

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44
* Silently downloads dependencies in the background on first CLI run:
55
* 1. @coana-tech/cli
66
* 2. @cyclonedx/cdxgen
7-
* 3. @socketbin/cli-ai
8-
* 4. Python + socketsecurity (socket-python-cli)
7+
* 3. Python + socketsecurity (socket-python-cli)
98
*
109
* Downloads are staggered sequentially to avoid resource contention.
1110
* This runs asynchronously and never blocks the main CLI execution.
@@ -50,7 +49,7 @@ export function runPreflightDownloads(): void {
5049
void (async () => {
5150
try {
5251
// Stagger downloads sequentially to avoid resource contention.
53-
// Order: coana → cdxgen → cli-ai → Python → socketsecurity.
52+
// Order: coana → cdxgen → Python → socketsecurity.
5453

5554
// 1. @coana-tech/cli preflight.
5655
const coanaVersion = ENV.INLINED_SOCKET_CLI_COANA_VERSION
@@ -74,18 +73,7 @@ export function runPreflightDownloads(): void {
7473
})
7574
}
7675

77-
// 3. @socketbin/cli-ai preflight.
78-
const cliAiVersion = ENV.INLINED_SOCKET_CLI_AI_VERSION
79-
const cliAiSpec = `@socketbin/cli-ai@^${cliAiVersion}`
80-
if (!isPackageCached(cliAiSpec)) {
81-
await downloadPackage({
82-
package: cliAiSpec,
83-
binaryName: 'cli-ai',
84-
force: false,
85-
})
86-
}
87-
88-
// 4. Python + socketsecurity (socket-python-cli) preflight.
76+
// 3. Python + socketsecurity (socket-python-cli) preflight.
8977
const pythonBin = await ensurePython()
9078
await ensureSocketCli(pythonBin)
9179
} catch {}

packages/socket/.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
11
/coverage
22
**/dist
3-
CHANGELOG.md
4-
LICENSE
5-
*.png

0 commit comments

Comments
 (0)