Skip to content

Commit

Permalink
chore: debug
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Phelps <[email protected]>
  • Loading branch information
markphelps committed Sep 7, 2024
1 parent eef753a commit 8c14574
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion package/ffi/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,7 @@ func dartBuild(ctx context.Context, client *dagger.Client, hostDirectory *dagger
}

out := buf.String()
fmt.Printf("out: %s\n", out)
buf.Reset()

jqCmd := exec.Command("sh", "-c", fmt.Sprintf("echo '%s' | jq -r '.value'", out))
Expand All @@ -509,8 +510,10 @@ func dartBuild(ctx context.Context, client *dagger.Client, hostDirectory *dagger
return fmt.Errorf("jq command failed: %w", err)
}

pubToken := client.SetSecret("pub-token", buf.String())
token := buf.String()
fmt.Printf("token: %s\n", token)

pubToken := client.SetSecret("pub-token", token)
_, err = container.WithSecretVariable("PUB_TOKEN", pubToken).
WithExec([]string{"dart", "pub", "token", "add", "https://pub.dev", "--env-var", "PUB_TOKEN"}).
WithExec([]string{"dart", "pub", "publish"}).
Expand Down

0 comments on commit 8c14574

Please sign in to comment.