Skip to content

Commit 0a8f1a1

Browse files
committed
A few more fixes
1 parent b4fe095 commit 0a8f1a1

File tree

4 files changed

+21
-4
lines changed

4 files changed

+21
-4
lines changed

apps/cli/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@roo-code/cli",
3-
"version": "0.1.0",
3+
"version": "0.2.2",
44
"description": "Roo Code CLI - Run the Roo Code agent from the command line",
55
"private": true,
66
"type": "module",

apps/cli/scripts/release.sh

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ create_tarball() {
130130
info "Copying CLI files..."
131131
cp -r "$CLI_DIR/dist/"* "$RELEASE_DIR/lib/"
132132

133-
# Create package.json for npm install (only runtime dependencies)
133+
# Create package.json for npm install (runtime dependencies that can't be bundled)
134134
info "Creating package.json..."
135135
node -e "
136136
const pkg = require('$CLI_DIR/package.json');
@@ -139,7 +139,11 @@ create_tarball() {
139139
version: pkg.version,
140140
type: 'module',
141141
dependencies: {
142-
commander: pkg.dependencies.commander
142+
'@inkjs/ui': pkg.dependencies['@inkjs/ui'],
143+
'commander': pkg.dependencies.commander,
144+
'ink': pkg.dependencies.ink,
145+
'react': pkg.dependencies.react,
146+
'zustand': pkg.dependencies.zustand
143147
}
144148
};
145149
console.log(JSON.stringify(newPkg, null, 2));
@@ -197,6 +201,9 @@ WRAPPER_EOF
197201
# Create version file
198202
echo "$VERSION" > "$RELEASE_DIR/VERSION"
199203

204+
# Create empty .env file to suppress dotenvx warnings
205+
touch "$RELEASE_DIR/.env"
206+
200207
# Create tarball
201208
info "Creating tarball..."
202209
cd "$REPO_ROOT"

apps/cli/src/index.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
import { Command } from "commander"
66
import fs from "fs"
7+
import { createRequire } from "module"
78
import path from "path"
89
import { fileURLToPath } from "url"
910
import { createElement } from "react"
@@ -29,9 +30,16 @@ const REASONING_EFFORTS = [...reasoningEffortsExtended, "unspecified", "disabled
2930

3031
const __dirname = path.dirname(fileURLToPath(import.meta.url))
3132

33+
// Read version from package.json
34+
const require = createRequire(import.meta.url)
35+
const packageJson = require("../package.json")
36+
3237
const program = new Command()
3338

34-
program.name("roo").description("Roo Code CLI - Run the Roo Code agent from the command line").version("0.1.0")
39+
program
40+
.name("roo")
41+
.description("Roo Code CLI - Run the Roo Code agent from the command line")
42+
.version(packageJson.version)
3543

3644
program
3745
.argument("[prompt]", "The prompt/task to execute (optional in TUI mode)")

apps/cli/tsup.config.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ export default defineConfig({
2020
"@anthropic-ai/vertex-sdk",
2121
// Keep @vscode/ripgrep external - we bundle the binary separately
2222
"@vscode/ripgrep",
23+
// Optional dev dependency of ink - not needed at runtime
24+
"react-devtools-core",
2325
],
2426
esbuildOptions(options) {
2527
// Enable JSX for React/Ink components

0 commit comments

Comments
 (0)