Skip to content

Commit

Permalink
fix: fix a lint error
Browse files Browse the repository at this point in the history
  • Loading branch information
suzuki-shunsuke committed Jan 29, 2025
1 parent b7e62ee commit 9e17395
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions pkg/installpackage/installer.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ type DownloadParam struct {
RequireChecksum bool
}

func (is *Installer) InstallPackages(ctx context.Context, logE *logrus.Entry, param *ParamInstallPackages) error { //nolint:funlen,cyclop
func (is *Installer) InstallPackages(ctx context.Context, logE *logrus.Entry, param *ParamInstallPackages) error { //nolint:cyclop
pkgs, failed := config.ListPackages(logE, param.Config, is.runtime, param.Registries)
if !param.SkipLink {
if failedCreateLinks := is.createLinks(logE, pkgs); failedCreateLinks {
Expand Down Expand Up @@ -219,16 +219,16 @@ func (is *Installer) InstallPackages(ctx context.Context, logE *logrus.Entry, pa
eg.SetLimit(is.maxParallelism)

for _, pkg := range pkgs {
logE := logE.WithFields(logrus.Fields{
"package_name": pkg.Package.Name,
"package_version": pkg.Package.Version,
"registry": pkg.Package.Registry,
})
if !aqua.FilterPackageByTag(pkg.Package, param.Tags, param.ExcludedTags) {
logE.Debug("skip installing the package because package tags are unmatched")
continue
}
eg.Go(func() error {
logE := logE.WithFields(logrus.Fields{
"package_name": pkg.Package.Name,
"package_version": pkg.Package.Version,
"registry": pkg.Package.Registry,
})
if !aqua.FilterPackageByTag(pkg.Package, param.Tags, param.ExcludedTags) {
logE.Debug("skip installing the package because package tags are unmatched")
return nil
}
if err := is.InstallPackage(ctx, logE, &ParamInstallPackage{
Pkg: pkg,
Checksums: param.Checksums,
Expand Down

0 comments on commit 9e17395

Please sign in to comment.