Skip to content

Commit 19be7cf

Browse files
committed
Fixed linter warnings
1 parent ab73120 commit 19be7cf

File tree

16 files changed

+27
-27
lines changed

16 files changed

+27
-27
lines changed

cli/board/attach.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ func runAttachCommand(cmd *cobra.Command, args []string) {
5757
if len(args) > 0 {
5858
path = args[1]
5959
}
60-
_, err := board.BoardAttach(context.Background(), &rpc.BoardAttachReq{
60+
_, err := board.Attach(context.Background(), &rpc.BoardAttachReq{
6161
Instance: instance,
6262
BoardUri: args[0],
6363
SketchPath: path,

cli/board/details.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ func initDetailsCommand() *cobra.Command {
4545
func runDetailsCommand(cmd *cobra.Command, args []string) {
4646
instance := cli.CreateInstance()
4747

48-
res, err := board.BoardDetails(context.Background(), &rpc.BoardDetailsReq{
48+
res, err := board.Details(context.Background(), &rpc.BoardDetailsReq{
4949
Instance: instance,
5050
Fqbn: args[0],
5151
})

cli/board/list.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ func runListCommand(cmd *cobra.Command, args []string) {
6262
time.Sleep(timeout)
6363
}
6464

65-
resp, err := board.BoardList(context.Background(), &rpc.BoardListReq{Instance: instance})
65+
resp, err := board.List(context.Background(), &rpc.BoardListReq{Instance: instance})
6666
if err != nil {
6767
formatter.PrintError(err, "Error detecting boards")
6868
os.Exit(cli.ErrNetwork)

cli/board/listall.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ func initListAllCommand() *cobra.Command {
5151
func runListAllCommand(cmd *cobra.Command, args []string) {
5252
instance := cli.CreateInstance()
5353

54-
list, err := board.BoardListAll(context.Background(), &rpc.BoardListAllReq{
54+
list, err := board.ListAll(context.Background(), &rpc.BoardListAllReq{
5555
Instance: instance,
5656
SearchArgs: args,
5757
})

cli/cli_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -576,11 +576,11 @@ board_manager:
576576
require.NoError(t, err, "Writing empty json index file")
577577

578578
// Empty cores list
579-
exitCode, d := executeWithArgs(t, "--config-file", configFile.String(), "core", "list")
579+
exitCode, _ := executeWithArgs(t, "--config-file", configFile.String(), "core", "list")
580580
require.Zero(t, exitCode, "exit code")
581581

582582
// Dump config with cmd-line specific file
583-
exitCode, d = executeWithArgs(t, "--config-file", configFile.String(), "config", "dump")
583+
exitCode, d := executeWithArgs(t, "--config-file", configFile.String(), "config", "dump")
584584
require.Zero(t, exitCode, "exit code")
585585
require.Contains(t, string(d), "- http://www.invalid-domain-asjkdakdhadjkh.com/package_example_index.json")
586586

cli/daemon/daemon.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ import (
2929
"google.golang.org/grpc"
3030
)
3131

32-
// InitCommand initalize the command
32+
// InitCommand initialize the command
3333
func InitCommand() *cobra.Command {
3434
cmd := &cobra.Command{
3535
Use: "daemon",

cli/root/root.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@ import (
2929
"github.com/arduino/arduino-cli/cli/daemon"
3030
"github.com/arduino/arduino-cli/cli/lib"
3131
"github.com/arduino/arduino-cli/cli/upload"
32+
"github.com/arduino/arduino-cli/cli/version"
3233
"github.com/arduino/arduino-cli/commands/config"
3334
"github.com/arduino/arduino-cli/commands/generatedocs"
3435
"github.com/arduino/arduino-cli/commands/sketch"
35-
"github.com/arduino/arduino-cli/cli/version"
3636
"github.com/arduino/arduino-cli/common/formatter"
3737
"github.com/arduino/arduino-cli/configs"
3838
paths "github.com/arduino/go-paths-helper"
@@ -42,7 +42,7 @@ import (
4242
"golang.org/x/crypto/ssh/terminal"
4343
)
4444

45-
// Init prepares the cobra root command.
45+
// Init prepares the cobra root command.
4646
func Init() *cobra.Command {
4747
command := &cobra.Command{
4848
Use: "arduino-cli",

commands/board/attach.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ import (
3434
paths "github.com/arduino/go-paths-helper"
3535
)
3636

37-
func BoardAttach(ctx context.Context, req *rpc.BoardAttachReq, taskCB commands.TaskProgressCB) (*rpc.BoardAttachResp, error) {
37+
func Attach(ctx context.Context, req *rpc.BoardAttachReq, taskCB commands.TaskProgressCB) (*rpc.BoardAttachResp, error) {
3838

3939
pm := commands.GetPackageManager(req)
4040
if pm == nil {

commands/board/details.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import (
2727
"github.com/arduino/arduino-cli/rpc"
2828
)
2929

30-
func BoardDetails(ctx context.Context, req *rpc.BoardDetailsReq) (*rpc.BoardDetailsResp, error) {
30+
func Details(ctx context.Context, req *rpc.BoardDetailsReq) (*rpc.BoardDetailsResp, error) {
3131
pm := commands.GetPackageManager(req)
3232
if pm == nil {
3333
return nil, errors.New("invalid instance")

commands/board/list.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ import (
2626
"github.com/arduino/arduino-cli/rpc"
2727
)
2828

29-
func BoardList(ctx context.Context, req *rpc.BoardListReq) (*rpc.BoardListResp, error) {
29+
func List(ctx context.Context, req *rpc.BoardListReq) (*rpc.BoardListResp, error) {
3030
pm := commands.GetPackageManager(req)
3131
if pm == nil {
3232
return nil, errors.New("invalid instance")

0 commit comments

Comments
 (0)