Skip to content

Commit

Permalink
f
Browse files Browse the repository at this point in the history
  • Loading branch information
marccampbell committed Oct 17, 2024
1 parent 69e283c commit e15faca
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions dagger/release.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,18 @@ func (r *Replicated) Release(
return fmt.Errorf("git tree is not clean")
}

if gitTreeOK {
return fmt.Errorf("git tree is clean")
}

major, minor, patch, err := parseVersion(ctx, version)
if err != nil {
return err
}

_ = dag.Container().
From("alpine/git:latest").
WithMountedDirectory("/go/src/github.com/replicatedhq/replicated", source).
WithWorkdir("/go/src/github.com/replicatedhq/replicated").
WithExec([]string{"git", "tag", fmt.Sprintf("v%d.%d.%d", major, minor, patch)}).
WithExec([]string{"git", "push", "origin", fmt.Sprintf("v%d.%d.%d", major, minor, patch)})

replicatedBinary := dag.Container().
From("golang:1.22").
WithMountedDirectory("/go/src/github.com/replicatedhq/replicated", source).
Expand Down

0 comments on commit e15faca

Please sign in to comment.