From 3eef4664f9e53854f6c30d714932fda10bf3151d Mon Sep 17 00:00:00 2001 From: Alik Khilazhev <7482065+alikhil@users.noreply.github.com> Date: Sun, 28 Sep 2025 17:28:49 +0200 Subject: [PATCH] fix golangci-lint issues Signed-off-by: Alik Khilazhev <7482065+alikhil@users.noreply.github.com> --- pkg/cmd/helpers_test.go | 12 ------------ pkg/downloader/manager.go | 4 +--- 2 files changed, 1 insertion(+), 15 deletions(-) diff --git a/pkg/cmd/helpers_test.go b/pkg/cmd/helpers_test.go index 5432ff2de..07f01b42b 100644 --- a/pkg/cmd/helpers_test.go +++ b/pkg/cmd/helpers_test.go @@ -165,18 +165,6 @@ func resetEnv() func() { } } -func testChdir(t *testing.T, dir string) func() { - t.Helper() - old, err := os.Getwd() - if err != nil { - t.Fatal(err) - } - if err := os.Chdir(dir); err != nil { - t.Fatal(err) - } - return func() { os.Chdir(old) } -} - // resetChartDependencyState completely resets dependency state of a given chart // by deleting `Chart.lock` and `charts/`. // diff --git a/pkg/downloader/manager.go b/pkg/downloader/manager.go index 6087bbd8b..503452a80 100644 --- a/pkg/downloader/manager.go +++ b/pkg/downloader/manager.go @@ -825,14 +825,12 @@ func (m *Manager) locateLocalDependencies(baseChartPath string, resursive bool) for _, chartDependency := range baseChart.Metadata.Dependencies { - fullDepChartPath := chartDependency.Repository - if strings.HasPrefix( chartDependency.Repository, "file://", ) { - fullDepChartPath, err = filepath.Abs( + fullDepChartPath, err := filepath.Abs( fmt.Sprintf( "%s/%s", baseChartPath, chartDependency.Repository[7:]), // removes "file://"