Skip to content

Commit

Permalink
feat: hide deprecated run command (#152)
Browse files Browse the repository at this point in the history
Signed-off-by: Ben Meier <[email protected]>
  • Loading branch information
astromechza authored Jun 19, 2024
1 parent 91f6a55 commit 25099c7
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ Global Flags:
-v, --verbose count Increase log verbosity and detail by specifying this flag one or more times
```

**NOTE**: The `score-compose run` command still exists but should be considered deprecated as it does not support resource provisioning.
**NOTE**: The `score-compose run` command still exists but is hidden and should be considered deprecated as it does not support resource provisioning.

## ![Get involved](docs/images/get-involved.svg) Get involved

Expand Down
1 change: 0 additions & 1 deletion internal/command/root_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ Available Commands:
help Help about any command
init Initialise a new score-compose project with local state directory and score file
resources Subcommands related to provisioned resources
run Translate the SCORE file to docker-compose configuration
Flags:
-h, --help help for score-compose
Expand Down
3 changes: 2 additions & 1 deletion internal/command/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ func init() {
var runCmd = &cobra.Command{
Use: "run [--file=score.yaml] [--output=compose.yaml]",
Args: cobra.NoArgs,
Short: "Translate the SCORE file to docker-compose configuration",
Short: "(Deprecated) Translate the SCORE file to docker-compose configuration",
Hidden: true,
RunE: run,
// don't print the errors - we print these ourselves in main()
SilenceErrors: true,
Expand Down
2 changes: 1 addition & 1 deletion internal/command/run_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ func executeAndResetCommand(ctx context.Context, cmd *cobra.Command, args []stri
func TestRunHelp(t *testing.T) {
stdout, stderr, err := executeAndResetCommand(context.Background(), rootCmd, []string{"run", "--help"})
assert.NoError(t, err)
assert.Equal(t, `Translate the SCORE file to docker-compose configuration
assert.Equal(t, `(Deprecated) Translate the SCORE file to docker-compose configuration
Usage:
score-compose run [--file=score.yaml] [--output=compose.yaml] [flags]
Expand Down

0 comments on commit 25099c7

Please sign in to comment.