Skip to content

Conversation

@Arul-
Copy link
Contributor

@Arul- Arul- commented Jan 17, 2026

The --profile option was using Commander.js variadic pattern (<names...>) which caused argument parsing conflicts when placed before positional args.

Changes:

  • Add parseProfiles() helper to handle comma-separated profile values
  • Change --profile <names...> to --profile for add/remove commands
  • Update all usages to use parseProfiles() for consistent array handling

Users can now specify profiles in any order:
ncp add --profile work github # Works correctly
ncp add github --profile work # Also works

Multiple profiles use comma-separation:
ncp add --profile work,personal github

Fixes #13

Pull Request

Description

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 💥 Breaking change (fix or feature that causes existing functionality to not work as expected)
  • 📚 Documentation update
  • 🔧 Configuration change
  • ⚡ Performance improvement
  • 🧪 Test additions or improvements
  • 🎨 Code style/formatting changes
  • 📦 Dependencies update

Related Issues

  • Closes #
  • Related to #

Changes Made

Added

Changed

Removed

Fixed

Testing

Test Environment

  • Local development
  • Docker container
  • Multiple Node.js versions
  • Multiple operating systems

Test Cases

  • Unit tests pass (npm test)
  • Integration tests pass
  • Manual testing completed
  • Edge cases considered

Test Commands Used

# Add commands used for testing
npm test
npm run build

MCP Server Compatibility

  • Tested with multiple MCP servers
  • No breaking changes to MCP protocol usage
  • Discovery/search functionality unaffected
  • Error handling improved/maintained

Documentation

  • README.md updated (if needed)
  • API documentation updated
  • Configuration examples updated
  • Migration guide provided (for breaking changes)

Performance Impact

  • No performance impact expected
  • Performance improvement included
  • Performance regression possible (explain below)

Screenshots/Examples

Checklist

Code Quality

  • Code follows project style guidelines
  • Self-review completed
  • Code is properly commented
  • No console.log or debug statements left
  • Error handling is appropriate

Security

  • No sensitive information exposed
  • Input validation added where needed
  • Security implications considered

Compatibility

  • Changes are backward compatible (or breaking changes documented)
  • Works with supported Node.js versions
  • Cross-platform compatibility maintained

Deployment Notes

  • No special deployment steps required
  • Configuration changes needed (document below)
  • Database migrations required
  • Environment variables added/changed

Reviewer Notes

Additional Context

The --profile option was using Commander.js variadic pattern (<names...>)
which caused argument parsing conflicts when placed before positional args.

Changes:
- Add parseProfiles() helper to handle comma-separated profile values
- Change --profile <names...> to --profile <names> for add/remove commands
- Update all usages to use parseProfiles() for consistent array handling

Users can now specify profiles in any order:
  ncp add --profile work github       # Works correctly
  ncp add github --profile work       # Also works

Multiple profiles use comma-separation:
  ncp add --profile work,personal github

Fixes #13
@Arul- Arul- force-pushed the claude/validate-issue-pr-K7ZXO branch from 5cf9c9a to a640e0f Compare January 17, 2026 13:23
@Arul- Arul- merged commit 290845e into main Jan 17, 2026
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.

[Bug]: ncp add --profile profile-name doesn't work

3 participants