Skip to content

Commit 77b5c9d

Browse files
committed
return a usage error if the command-line is still used
1 parent 9c30e55 commit 77b5c9d

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

cmd/src/login.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import (
99
"os"
1010

1111
"github.com/sourcegraph/src-cli/internal/api"
12+
"github.com/sourcegraph/src-cli/internal/cmderrors"
1213
"github.com/sourcegraph/src-cli/internal/oauth"
1314
)
1415

@@ -45,6 +46,10 @@ Examples:
4546
return err
4647
}
4748

49+
if flagSet.NArg() > 0 {
50+
return cmderrors.Usage("src login no longer accepts a URL argument; set SRC_ENDPOINT instead")
51+
}
52+
4853
client := cfg.apiClient(nil, io.Discard)
4954

5055
return loginCmd(context.Background(), loginParams{

0 commit comments

Comments
 (0)