mirror of https://github.com/docker/cli.git
update go:build tags to use go1.22
commit 4a7b04d412
configured golangci-lint
to use go1.23 semantics, which enabled the copyloopvar linter.
go1.22 now creates a copy of variables when assigned in a loop; make sure we
don't have files that may downgrade semantics to go1.21 in case that also means
disabling that feature; https://go.dev/ref/spec#Go_1.22
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
917d2dc837
commit
7c80e4f938
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package manager
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package config
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package container
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package context
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package context
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package context
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package context
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package formatter
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package idresolver
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package image
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package image
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package inspect
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package network
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package network
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package node
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package node
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package plugin
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package plugin
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package secret
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package service
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package service
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package service
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package service
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package system
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package system
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(jsternberg): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package trust
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package command
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package volume
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package interpolation
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package interpolation
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package loader
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package schema
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package schema
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package template
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package template
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package types
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package store
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package store
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package store
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package store
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package store
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package store
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package api
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package main
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
// FIXME(thaJeztah): remove once we are a module; the go:build directive prevents go from downgrading language version to go1.16:
|
||||
//go:build go1.21
|
||||
//go:build go1.22
|
||||
|
||||
package templates
|
||||
|
||||
|
|
Loading…
Reference in New Issue