fix: stop command missing --name flag to specify which instance to stop

Open Beginner friendly
#438 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
72/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
go
Domain
cli

Research direction

Start at the stop command entry point and compare its flags and context resolution with the start command, focusing on ResolveContext(). Verify the command help exposes --name, confirm the name reaches context resolution, and check that stopping a named instance works without the unnecessary empty output.

Written by the indexing model from the issue text.

Description

Why we need this:
The start command supports --name flag to name a Microcks instance
but the stop command has no --name flag. Users cannot specify which
instance to stop when multiple instances exist.

How this will help:
Adding --name flag to stop command makes it consistent with start
command and allows users to stop a specific named instance.

Problem

microcks start --name myinstance ✅ works
microcks stop --name myinstance ❌ flag does not exist

The stop command always resolves the current context instead of
allowing the user to specify which instance to stop by name.

Fix

  • Add --name flag to stop command
  • Pass name to ResolveContext() so correct instance is stopped
  • Remove unnecessary empty fmt.Println() call
Dominant language
Go
Stars
52
Forks
67
Avg merge
1d 1h
Merged PRs (30d)
13

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microcks/microcks-cli

All issues in microcks/microcks-cli

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.