Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start using goimports #1399

Merged
merged 4 commits into from
Nov 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ linters:
- gci
- godot
- gofmt
- goimports
- misspell
- whitespace
- revive
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-agent/api_1.0.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (

"github.com/mdlayher/vsock"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/linux"
"github.com/lxc/incus/v6/internal/ports"
"github.com/lxc/incus/v6/internal/server/response"
Expand Down
4 changes: 2 additions & 2 deletions cmd/incus-agent/dev_incus.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ import (

"github.com/gorilla/mux"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/server/daemon"
"github.com/lxc/incus/v6/internal/server/device/config"
localUtil "github.com/lxc/incus/v6/internal/server/util"
"github.com/lxc/incus/v6/shared/api/guest"
api "github.com/lxc/incus/v6/shared/api/guest"
"github.com/lxc/incus/v6/shared/logger"
"github.com/lxc/incus/v6/shared/util"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-benchmark/benchmark.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"sync"
"time"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/version"
"github.com/lxc/incus/v6/shared/api"
config "github.com/lxc/incus/v6/shared/cliconfig"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-benchmark/benchmark_operation.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package main

import (
"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/shared/api"
)

Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-benchmark/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/version"
"github.com/lxc/incus/v6/shared/api"
"github.com/lxc/incus/v6/shared/util"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-migrate/main_migrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
"golang.org/x/sys/unix"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/linux"
"github.com/lxc/incus/v6/internal/version"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-migrate/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (

"golang.org/x/sys/unix"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/migration"
"github.com/lxc/incus/v6/internal/ports"
internalUtil "github.com/lxc/incus/v6/internal/util"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-user/main_daemon.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/linux"
internalUtil "github.com/lxc/incus/v6/internal/util"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus-user/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"strconv"
"strings"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/linux"
internalUtil "github.com/lxc/incus/v6/internal/util"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_init.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/ports"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_init_auto.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/linux"
"github.com/lxc/incus/v6/internal/ports"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_init_dump.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (

yaml "gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_init_interactive.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
"golang.org/x/sys/unix"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/linux"
"github.com/lxc/incus/v6/internal/ports"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_init_preseed.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_recover.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"golang.org/x/text/cases"
"golang.org/x/text/language"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/recover"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_shutdown.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_sql.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
internalSQL "github.com/lxc/incus/v6/internal/sql"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/admin_waitready.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/logger"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/console.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"github.com/gorilla/websocket"
"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/copy.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/exec.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"github.com/gorilla/websocket"
"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/export.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/file.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"github.com/spf13/cobra"
"golang.org/x/crypto/ssh"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
internalIO "github.com/lxc/incus/v6/internal/io"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/image.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
internalUtil "github.com/lxc/incus/v6/internal/util"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/import.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/ioprogress"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/info.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
internalUtil "github.com/lxc/incus/v6/internal/util"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/monitor.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/publish.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/remote.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/ports"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/remote_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/snapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/storage_bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/storage_volume.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"github.com/spf13/cobra"
"gopkg.in/yaml.v2"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/top.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (

"github.com/spf13/cobra"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
cli "github.com/lxc/incus/v6/internal/cmd"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/shared/units"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incus/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"sort"
"strings"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/i18n"
"github.com/lxc/incus/v6/internal/instance"
"github.com/lxc/incus/v6/shared/api"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incusd/api_1.0.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"os"
"strings"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/server/auth"
"github.com/lxc/incus/v6/internal/server/auth/oidc"
"github.com/lxc/incus/v6/internal/server/cluster"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incusd/api_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (

"github.com/gorilla/mux"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
internalInstance "github.com/lxc/incus/v6/internal/instance"
"github.com/lxc/incus/v6/internal/server/auth"
"github.com/lxc/incus/v6/internal/server/certificate"
Expand Down
2 changes: 1 addition & 1 deletion cmd/incusd/api_cluster_certificate.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"net/http"
"os"

"github.com/lxc/incus/v6/client"
incus "github.com/lxc/incus/v6/client"
"github.com/lxc/incus/v6/internal/server/acme"
"github.com/lxc/incus/v6/internal/server/auth"
"github.com/lxc/incus/v6/internal/server/cluster"
Expand Down
Loading
Loading