Skip to content

Commit abc1cc7

Browse files
committed
tools/geneos: actually fix downloads to avoid aarch64 releases for now and update PathTo() to support strings directly
1 parent f5db7f2 commit abc1cc7

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

tools/geneos/internal/geneos/archives.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -630,7 +630,9 @@ func openRemoteDefaultArchive(ct *Component, opts *geneosOptions) (source string
630630
}
631631
v.Set("title", opts.version)
632632
} else if platform != "" {
633-
v.Set("title", "-"+platform+"-linux")
633+
v.Set("title", "-"+platform+"-linux-x64")
634+
} else {
635+
v.Set("title", "linux-x64")
634636
}
635637

636638
basepaths := strings.FieldsFunc(ct.DownloadBase.Default, func(r rune) bool {

tools/geneos/internal/geneos/host.go

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ func (h *Host) OrList(hosts ...*Host) []*Host {
329329
// If calling this against the "packages" directory remember to use
330330
// ct.String() to not deference the parent type, which is done if a part
331331
// is a *Component
332-
func (h *Host) PathTo(parts ...interface{}) string {
332+
func (h *Host) PathTo(parts ...any) string {
333333
if h == nil {
334334
h = LOCAL
335335
}
@@ -344,12 +344,14 @@ func (h *Host) PathTo(parts ...interface{}) string {
344344
} else {
345345
strParts = append(strParts, s.Name)
346346
}
347-
case []interface{}:
347+
case []any:
348348
for _, t := range s {
349349
strParts = append(strParts, fmt.Sprint(t))
350350
}
351-
// case string:
352-
// strParts = append(strParts, s)
351+
case string:
352+
strParts = append(strParts, s)
353+
case fmt.Stringer:
354+
strParts = append(strParts, s.String())
353355
default:
354356
strParts = append(strParts, fmt.Sprint(s))
355357
}

0 commit comments

Comments
 (0)