Fix npm publishing warnings and clean up package.json files

- Fixed repository URLs to use git+https:// format
- Removed tsconfig.tsbuildinfo from clean scripts
- Updated README with clearer build instructions and dependency order
- Fixed bin paths to reference dist/cli.js correctly
- Ready for npm publishing with no warnings
This commit is contained in:
Mario Zechner 2025-08-09 17:27:16 +02:00
parent a74c5da112
commit c615f3f011
5 changed files with 23 additions and 31 deletions

View file

@ -12,34 +12,24 @@ A collection of tools for managing LLM deployments and building AI agents.
This is a monorepo using npm workspaces for package management and a dual TypeScript configuration for development and building.
### Setup
### Common Commands
```bash
# Install all dependencies
npm install
# Build all packages (required for production use)
# Build all packages (required for publishing to NPM)
npm run build
# Or run directly with tsx during development (no build needed)
cd packages/pods && npx tsx src/cli.ts
cd packages/agent && npx tsx src/cli.ts
```
### Common Commands
```bash
# Clean all build artifacts and tsconfig.tsbuildinfo files
# Clean out dist/ folders in all packages
npm run clean
# Build all packages in dependency order
npm run build
# Run biome checks and TypeScript type checking (no build required)
# Run linting, formatting, and tsc typechecking (no build needed)
npm run check
# Run tests (if present)
npm run test
# Run directly with tsx during development (no build needed)
cd packages/pods && npx tsx src/cli.ts
cd packages/agent && npx tsx src/cli.ts
```
### Package Dependencies
@ -48,6 +38,8 @@ The packages have the following dependency structure:
`pi-tui` -> `pi-agent` -> `pi`
When new packages are added, the must be inserted in the correct order in the `build` script in `package.json`.
### TypeScript Configuration
The monorepo uses a dual TypeScript configuration approach:
@ -89,7 +81,7 @@ Quick version:
npm run publish:dry
# Publish all packages to npm
npm run publish:all
npm run publish
```
## License

View file

@ -14,10 +14,9 @@
"version:minor": "npm version minor -ws --no-git-tag-version && node scripts/sync-versions.js",
"version:major": "npm version major -ws --no-git-tag-version && node scripts/sync-versions.js",
"version:set": "npm version -ws",
"version:sync": "node scripts/sync-versions.js",
"prepublish:all": "npm run clean && npm run build && npm run check",
"publish:all": "npm run prepublish:all && npm publish -ws --access public",
"publish:dry": "npm run prepublish:all && npm publish -ws --access public --dry-run"
"prepublish": "npm run clean && npm run build && npm run check",
"publish": "npm run prepublish && npm publish -ws --access public",
"publish:dry": "npm run prepublish && npm publish -ws --access public --dry-run"
},
"devDependencies": {
"@biomejs/biome": "^2.1.4",
@ -27,5 +26,6 @@
},
"engines": {
"node": ">=20.0.0"
}
},
"version": ""
}

View file

@ -4,7 +4,7 @@
"description": "General-purpose agent with tool calling and session persistence",
"type": "module",
"bin": {
"pi-agent": "./dist/cli.js"
"pi-agent": "dist/cli.js"
},
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
@ -12,7 +12,7 @@
"dist"
],
"scripts": {
"clean": "rm -rf dist tsconfig.tsbuildinfo",
"clean": "rm -rf dist",
"build": "tsc -p tsconfig.build.json && chmod +x dist/cli.js",
"check": "biome check --write .",
"prepublishOnly": "npm run clean && npm run build"
@ -38,7 +38,7 @@
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/badlogic/pi-mono.git",
"url": "git+https://github.com/badlogic/pi-mono.git",
"directory": "packages/agent"
},
"engines": {

View file

@ -4,10 +4,10 @@
"description": "CLI tool for managing vLLM deployments on GPU pods",
"type": "module",
"bin": {
"pi": "./dist/cli.js"
"pi": "dist/cli.js"
},
"scripts": {
"clean": "rm -rf dist tsconfig.tsbuildinfo",
"clean": "rm -rf dist",
"build": "tsc -p tsconfig.build.json && chmod +x dist/cli.js && cp src/models.json dist/",
"check": "biome check --write .",
"prepublishOnly": "npm run clean && npm run build"
@ -26,7 +26,7 @@
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/badlogic/pi-mono.git",
"url": "git+https://github.com/badlogic/pi-mono.git",
"directory": "packages/pods"
},
"engines": {

View file

@ -5,7 +5,7 @@
"type": "module",
"main": "dist/index.js",
"scripts": {
"clean": "rm -rf dist tsconfig.tsbuildinfo",
"clean": "rm -rf dist",
"build": "tsc -p tsconfig.build.json",
"check": "biome check --write .",
"prepublishOnly": "npm run clean && npm run build"
@ -27,7 +27,7 @@
"license": "MIT",
"repository": {
"type": "git",
"url": "https://github.com/badlogic/pi-mono.git",
"url": "git+https://github.com/badlogic/pi-mono.git",
"directory": "packages/tui"
},
"engines": {