Skip to content

Commit

Permalink
Removed commit hash from version number
Browse files Browse the repository at this point in the history
  • Loading branch information
runabol committed Nov 10, 2023
1 parent 4082713 commit 67046d6
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 10 deletions.
4 changes: 2 additions & 2 deletions health/health.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@ func (b *HealthCheck) Do(ctx context.Context) HealthCheckResult {
log.Error().Err(err).Msgf("failed %s healthcheck", name)
return HealthCheckResult{
Status: StatusDown,
Version: tork.FormattedVersion(),
Version: tork.Version,
}
}
}
return HealthCheckResult{
Status: StatusUp,
Version: tork.FormattedVersion(),
Version: tork.Version,
}
}
2 changes: 1 addition & 1 deletion internal/coordinator/coordinator.go
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ func (c *Coordinator) sendHeartbeats() {
CPUPercent: cpuPercent,
LastHeartbeatAt: time.Now().UTC(),
Hostname: hostname,
Version: tork.FormattedVersion(),
Version: tork.Version,
},
)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion internal/worker/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ func (w *Worker) sendHeartbeats() {
LastHeartbeatAt: time.Now().UTC(),
Hostname: hostname,
TaskCount: int(atomic.LoadInt32(&w.taskCount)),
Version: tork.FormattedVersion(),
Version: tork.Version,
},
)
if err != nil {
Expand Down
6 changes: 0 additions & 6 deletions version.go
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
package tork

import "fmt"

const (
Version = "0.1.42"
)

var (
GitCommit string = "develop"
)

func FormattedVersion() string {
return fmt.Sprintf("%s (%s)", Version, GitCommit)
}

0 comments on commit 67046d6

Please sign in to comment.