Skip to content

Commit

Permalink
Fix src batch repo file parameter parsing (#919)
Browse files Browse the repository at this point in the history
  • Loading branch information
eseliger authored Jan 12, 2023
1 parent 8110514 commit de8f6e6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ All notable changes to `src-cli` are documented in this file.
### Fixed

- Fix network timeout in `src users clean` occuring in instances with many users [#901](https://github.com/sourcegraph/src-cli/pull/901)
- Aligned parsing of spec file parameter of `src batch repos` with other commands. [#919](https://github.com/sourcegraph/src-cli/pull/919)

### Removed

Expand Down
10 changes: 5 additions & 5 deletions cmd/src/batch_repositories.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ Examples:
return err
}

file, err := getBatchSpecFile(flagSet, fileFlag)
if err != nil {
return err
}

ctx := context.Background()
client := cfg.apiClient(apiFlags, flagSet.Output())

Expand All @@ -73,11 +78,6 @@ Examples:
return err
}

var file string
if fileFlag != nil {
file = *fileFlag
}

out := output.NewOutput(flagSet.Output(), output.OutputOpts{Verbose: *verbose})
spec, _, _, err := parseBatchSpec(ctx, file, svc)
if err != nil {
Expand Down

0 comments on commit de8f6e6

Please sign in to comment.