Skip to content

Add wish/wrapper control plane CLI package#160

Draft
subtleGradient wants to merge 1 commit intoeffect-native/mainfrom
codex/create-@effect-native/wrp-control-plane-package
Draft

Add wish/wrapper control plane CLI package#160
subtleGradient wants to merge 1 commit intoeffect-native/mainfrom
codex/create-@effect-native/wrp-control-plane-package

Conversation

@subtleGradient
Copy link
Member

Summary

  • add new @effect-native/wrp package with CLI commands for init/add/list/show/eval/repo list
  • implement markdown-backed node parsing, workspace initialization, and targets loader
  • cover core workflows with vitest smoke tests

Testing

  • nix develop --command pnpm -C packages-native/wrp test -- --run

Codex Task

Copy link
Member Author

@subtleGradient subtleGradient left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead of node:fs or node:path

Comment on lines +16 to +19
Effect.tryPromise({
try: () => fs.readFile(configPath, "utf8"),
catch: (error) => error as Error
})
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +23 to +27
const configPath = path.join(rootDir, "wrp.config.json")
const exists = yield* Effect.tryPromise({
try: () => fs.access(configPath).then(() => true).catch(() => false),
catch: (error) => error as Error
})
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +33 to +34
const content = yield* readConfigFile(configPath)
const parsed = JSON.parse(content) as Partial<WrpConfig>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use Effect Schema instead

Comment on lines +11 to +14
Effect.tryPromise({
try: () => fs.access(filePath).then(() => true).catch(() => false),
catch: (error) => error as Error
})
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +16 to +26
const ensureDir = (dir: string) =>
Effect.tryPromise({
try: () => fs.mkdir(dir, { recursive: true }),
catch: (error) => error as Error
})

const writeFile = (filePath: string, content: string) =>
Effect.tryPromise({
try: () => fs.writeFile(filePath, content, "utf8"),
catch: (error) => error as Error
})
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +83 to +84
const promptgraphRoot = path.join(rootDir, config.promptgraphDir)
const targetsRoot = path.join(rootDir, config.targetsDir)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +1 to +2
import { promises as fs } from "node:fs"
import path from "node:path"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

@@ -0,0 +1,15 @@
import { spawn } from "node:child_process"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +1 to +2
import { promises as fs } from "node:fs"
import path from "node:path"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Comment on lines +1 to +2
import { promises as fs } from "node:fs"
import path from "node:path"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use @effect/platform instead

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant