Skip to content

Conversation

@rbren
Copy link
Contributor

@rbren rbren commented Nov 1, 2025

Summary

This PR adds GitHub Actions workflow to publish the TypeScript client as a package to GitHub Packages (the most GitHub-native approach), removes npm publishing, and updates the package name to @openhands/typescript-client.

Changes Made

🔧 Package Configuration

  • Updated package name from @openhands/agent-server-typescript-client to @openhands/typescript-client
  • Removed npm publishing - now exclusively uses GitHub Packages
  • Added .npmrc configuration for GitHub Packages scope

🚀 GitHub Actions Workflows

  • Updated .github/workflows/release.yml - Main workflow that publishes to GitHub Packages on tag push
  • Added .github/workflows/publish-github-packages.yml - Alternative workflow with manual trigger option
  • Modern GitHub Actions - Uses latest action versions, no deprecated actions
  • Automatic versioning from git tags
  • Comprehensive testing before publishing

📚 Documentation Updates

  • Updated README.md with GitHub Packages installation instructions
  • Updated PUBLISHING.md with GitHub Packages only publishing guide
  • Updated all import examples to use new package name

How to Publish

The easiest and most GitHub-native way is to simply push a version tag:

git tag v1.0.0
git push origin v1.0.0

This automatically:

  • ✅ Runs tests
  • ✅ Builds the package
  • ✅ Publishes to GitHub Packages
  • ✅ Creates a GitHub release with installation instructions

How Users Install

Option 1: Configure .npmrc (Recommended)

echo "@openhands:registry=https://npm.pkg.github.com" >> .npmrc
npm install @openhands/typescript-client

Option 2: Direct install with registry flag

npm install @openhands/typescript-client --registry=https://npm.pkg.github.com

Testing

  • ✅ Build passes: npm run build
  • ✅ Tests pass: npm test
  • ✅ Package name updated throughout codebase
  • ✅ Documentation updated with new installation instructions

Benefits

  • Most GitHub-native approach - Uses GitHub Packages exclusively
  • Simplified workflow - No need for npm tokens or dual publishing
  • Automatic GitHub integration - Leverages built-in GitHub token
  • Cleaner package name - Shorter and more intuitive
  • Complete automation - Tag-based publishing with zero manual steps

@rbren can click here to continue refining the PR

- Remove npm publishing and keep only GitHub Packages (most GitHub-native)
- Update package name to @openhands/typescript-client
- Add GitHub Actions workflow for automated publishing on tag push
- Update documentation and installation instructions
- Add .npmrc configuration for GitHub Packages scope

Co-authored-by: openhands <openhands@all-hands.dev>
@rbren rbren marked this pull request as ready for review November 1, 2025 01:06
@rbren rbren merged commit 2b47470 into main Nov 1, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants