Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: nil pointer in saucectl configure command #987

Merged
merged 2 commits into from
Dec 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,25 @@ jobs:
saucectl
saucectl.exe

test-configure:
needs: build
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v4

- name: Download saucectl Binary
uses: actions/download-artifact@v4
with:
name: saucectlbin

- name: Set Permissions
run: chmod +x ./saucectl

- name: Saucectl Configure
run: ./saucectl configure -u $SAUCE_USERNAME -a $SAUCE_ACCESS_KEY

puppeteer-replay:
needs: build
runs-on: ubuntu-latest
Expand Down
1 change: 0 additions & 1 deletion internal/cmd/configure/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ func Command() *cobra.Command {
go func() {
tracker.Collect(
cmds.FullName(cmd),
nil,
)
_ = tracker.Close()
}()
Expand Down
4 changes: 3 additions & 1 deletion internal/usage/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,9 @@ func (c *Client) Collect(subject string, opts ...Option) {
Set("ci", ci.GetProvider().Name)

for _, opt := range opts {
opt(p)
if opt != nil {
opt(p)
}
}

userID := credentials.Get().Username
Expand Down
Loading