Skip to content

Commit d027426

Browse files
Segment fix (#227)
* report only 1 event for creating components * bump
1 parent 49245ca commit d027426

File tree

5 files changed

+12
-7
lines changed

5 files changed

+12
-7
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VERSION=v0.0.207
1+
VERSION=v0.0.208
22

33
OUT_DIR=dist
44
YEAR?=$(shell date +"%Y")

cmd/commands/runtime.go

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -522,12 +522,17 @@ func RunRuntimeInstall(ctx context.Context, opts *RuntimeInstallOptions) error {
522522
infoStr := fmt.Sprintf("Creating component '%s'", component.Name)
523523
log.G(ctx).Infof(infoStr)
524524
err = component.CreateApp(ctx, opts.KubeFactory, opts.InsCloneOpts, opts.RuntimeName, store.Get().CFComponentType, "", "")
525-
handleCliStep(reporter.InstallStepCreateComponent, infoStr, err, true)
526525
if err != nil {
527-
return util.DecorateErrorWithDocsLink(fmt.Errorf("failed to create '%s' application: %w", component.Name, err))
526+
err = util.DecorateErrorWithDocsLink(fmt.Errorf("failed to create '%s' application: %w", component.Name, err))
527+
break
528528
}
529529
}
530530

531+
handleCliStep(reporter.InstallStepCreateComponents, "Creating components", err, true)
532+
if err != nil {
533+
return err
534+
}
535+
531536
err = installComponents(ctx, opts, rt)
532537
handleCliStep(reporter.InstallStepInstallComponenets, "Installing components", err, true)
533538
if err != nil {

docs/releases/release_notes.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ cf version
2323

2424
```bash
2525
# download and extract the binary
26-
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.207/cf-linux-amd64.tar.gz | tar zx
26+
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.208/cf-linux-amd64.tar.gz | tar zx
2727

2828
# move the binary to your $PATH
2929
mv ./cf-linux-amd64 /usr/local/bin/cf
@@ -36,7 +36,7 @@ cf version
3636

3737
```bash
3838
# download and extract the binary
39-
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.207/cf-darwin-amd64.tar.gz | tar zx
39+
curl -L --output - https://github.com/codefresh-io/cli-v2/releases/download/v0.0.208/cf-darwin-amd64.tar.gz | tar zx
4040

4141
# move the binary to your $PATH
4242
mv ./cf-darwin-amd64 /usr/local/bin/cf

manifests/runtime.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ metadata:
55
namespace: '{{ namespace }}'
66
spec:
77
defVersion: 1.0.0
8-
version: 0.0.207
8+
version: 0.0.208
99
bootstrapSpecifier: github.com/codefresh-io/cli-v2/manifests/argo-cd
1010
components:
1111
- name: events

pkg/reporter/reporter.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ const (
8282
InstallStepBootstrapRepo CliStep = "install.run.step.bootstrap-repo"
8383
InstallStepCreateProject CliStep = "install.run.step.create-project"
8484
InstallStepCreateConfigMap CliStep = "install.run.step.create-codefresh-cm"
85-
InstallStepCreateComponent CliStep = "install.run.step.create-component"
85+
InstallStepCreateComponents CliStep = "install.run.step.create-components"
8686
InstallStepInstallComponenets CliStep = "install.run.step.install-components"
8787
InstallStepCreateGitsource CliStep = "install.run.step.create-gitsource"
8888
InstallStepCreateMarketplaceGitsource CliStep = "install.run.step.create-marketplace-gitsource"

0 commit comments

Comments
 (0)