swadhinbiswas ✨ feat(cli): harden auth, TLS, retries, and repo parsing · 1/22/2026
bdf41c6
47 lines · 896 Bytes
Raw Download

title: "Publishing Guide"

NPM Registry

To publish the OpenCodeHub CLI to the official npm registry:

  1. Login to npm:

    npm login
    
  2. Run the publish script:

    ./scripts/publish-cli.sh
    

GitHub Packages (Other Registry)

To publish to GitHub Packages:

  1. Configure .npmrc:
    Create a .npmrc file in cli/ with:

    @swadhinbiswas:registry=https://npm.pkg.github.com
    
  2. Update Package Name:
    In cli/package.json, change the name to allow scoped publishing:

    "name": "@swadhinbiswas/opencodehub-cli"
    
  3. Authenticate:
    Generate a Value Access Token (PAT) with write:packages scope on GitHub.

    npm login --scope=@swadhinbiswas --registry=https://npm.pkg.github.com
    
  4. Publish:

    cd cli
    npm publish