Skip to content

feat: integrate credential manager#49

Open
michaelmalave wants to merge 32 commits intofeat/ruby-to-typescriptfrom
feat/integrate-credential-mgmt
Open

feat: integrate credential manager#49
michaelmalave wants to merge 32 commits intofeat/ruby-to-typescriptfrom
feat/integrate-credential-mgmt

Conversation

@michaelmalave
Copy link
Copy Markdown

Summary

Replaced direct netrc parsing with the heroku-credentials-manager from @heroku-cli/command@13.0.0-beta.1 for token retrieval.

Type of Change

  • fix: Bug fix or issue (patch semvar update)
  • feat: Introduces a new feature to the codebase (minor semvar update)
  • perf: Performance improvement
  • docs: Documentation only changes
  • tests: Adding missing tests or correcting existing tests
  • chore: Code cleanup tasks, dependency updates, or other changes

Verification

# Build and run tests
npm run build
npm test

# Manual verification (requires heroku login)
./bin/run devcenter:pull slowdb 
./bin/run devcenter:push slowdb

# Test with HEROKU_API_KEY env var
HEROKU_API_KEY=your-token ./bin/run devcenter:pull slowdb

All 72 tests pass with 80.23% coverage (meets 80% threshold).

Additional Context

  • Updated @heroku-cli/command from ^12.2.0 to ^13.0.0-beta.1
  • Removed direct netrc-parser dependency (now handled by credential manager)
  • Token retrieval precedence: HEROKU_API_KEY env var → native keychain → netrc fallback
  • getHerokuApiToken() is now async; commands updated to use await
  • Basic auth encoding preserved for Dev Center API compatibility
  • Added esmock as dev dependency for ESM module mocking in tests
  • Deleted unused test helpers (netrc-path.ts, test-home-env.ts)
  • Added additional paths.ts tests to maintain coverage threshold

Related Issue

Closes #W-22034106

michaelmalave and others added 30 commits April 9, 2026 13:25
…stored lib unit tests, components inventory, npm/GitHub Actions Dependabot, and plugin usage updates to README
…etrc on Windows and .netrc elsewhere, matching netrc-parser
Co-authored-by: Katy Bowman <katy.bowman@salesforce.com>
Signed-off-by: Michael Malave <michael.malave@salesforce.com>
…, use ux.stdout, stub browser opens via sinon, add nock init, switch to shared ESLint config, and align tsconfig/package.json with CLI
…indentation and camelcase issues in unit tests
@michaelmalave michaelmalave requested a review from a team as a code owner April 15, 2026 23:19
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.

1 participant