Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
arduino-cli
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Operations
Operations
Metrics
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
arduino-cli
Commits
32d8833d
Unverified
Commit
32d8833d
authored
Mar 25, 2024
by
Alessio Perugini
Committed by
GitHub
Mar 25, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[skip-changelog] bump golangci-lint to v1.57.x (#2571)
parent
6faca0f7
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
12 deletions
+12
-12
.github/workflows/check-go-task.yml
.github/workflows/check-go-task.yml
+1
-1
.golangci.yml
.golangci.yml
+1
-1
commands/instances.go
commands/instances.go
+7
-7
internal/cli/feedback/warn_deprecated.go
internal/cli/feedback/warn_deprecated.go
+3
-3
No files found.
.github/workflows/check-go-task.yml
View file @
32d8833d
...
...
@@ -116,7 +116,7 @@ jobs:
-
name
:
golangci-lint
uses
:
golangci/golangci-lint-action@v4
with
:
version
:
v1.5
5
version
:
v1.5
7
-
name
:
Check style
env
:
...
...
.golangci.yml
View file @
32d8833d
...
...
@@ -81,7 +81,7 @@ linters-settings:
issues
:
# Fix found issues (if it's supported by the linter).
fix
:
tru
e
fix
:
fals
e
# List of regexps of issue texts to exclude.
#
# But independently of this option we use default exclude patterns,
...
...
commands/instances.go
View file @
32d8833d
...
...
@@ -480,7 +480,7 @@ func UpdateIndex(ctx context.Context, req *rpc.UpdateIndexRequest, downloadCB rp
downloadCB
.
Start
(
u
,
tr
(
"Downloading index: %s"
,
u
))
downloadCB
.
End
(
false
,
msg
)
failed
=
true
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
continue
}
...
...
@@ -498,9 +498,9 @@ func UpdateIndex(ctx context.Context, req *rpc.UpdateIndexRequest, downloadCB rp
downloadCB
.
Start
(
u
,
tr
(
"Downloading index: %s"
,
filepath
.
Base
(
URL
.
Path
)))
downloadCB
.
End
(
false
,
msg
)
failed
=
true
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
}
else
{
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_SKIPPED
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_SKIPPED
))
}
continue
}
...
...
@@ -512,14 +512,14 @@ func UpdateIndex(ctx context.Context, req *rpc.UpdateIndexRequest, downloadCB rp
downloadCB
.
Start
(
u
,
tr
(
"Downloading index: %s"
,
filepath
.
Base
(
URL
.
Path
)))
downloadCB
.
End
(
false
,
tr
(
"Invalid index URL: %s"
,
err
))
failed
=
true
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
continue
}
indexFile
:=
indexpath
.
Join
(
indexFileName
)
if
info
,
err
:=
indexFile
.
Stat
();
err
==
nil
{
ageSecs
:=
int64
(
time
.
Since
(
info
.
ModTime
())
.
Seconds
())
if
ageSecs
<
req
.
GetUpdateIfOlderThanSecs
()
{
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_ALREADY_UP_TO_DATE
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_ALREADY_UP_TO_DATE
))
continue
}
}
...
...
@@ -530,9 +530,9 @@ func UpdateIndex(ctx context.Context, req *rpc.UpdateIndexRequest, downloadCB rp
}
if
err
:=
indexResource
.
Download
(
indexpath
,
downloadCB
);
err
!=
nil
{
failed
=
true
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_FAILED
))
}
else
{
result
.
UpdatedIndexes
=
append
(
result
.
UpdatedIndexes
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_UPDATED
))
result
.
UpdatedIndexes
=
append
(
result
.
GetUpdatedIndexes
()
,
report
(
URL
,
rpc
.
IndexUpdateReport_STATUS_UPDATED
))
}
}
...
...
internal/cli/feedback/warn_deprecated.go
View file @
32d8833d
...
...
@@ -25,13 +25,13 @@ import (
// WarnAboutDeprecatedFiles warns the user that a type of sketch files are deprecated
func
WarnAboutDeprecatedFiles
(
s
*
rpc
.
Sketch
)
{
var
files
[]
string
for
_
,
f
:=
range
s
.
OtherSketchFiles
{
for
_
,
f
:=
range
s
.
GetOtherSketchFiles
()
{
if
strings
.
HasSuffix
(
f
,
".pde"
)
{
files
=
append
(
files
,
f
)
}
}
if
strings
.
HasSuffix
(
s
.
MainFile
,
".pde"
)
{
files
=
append
(
files
,
s
.
MainFile
)
if
strings
.
HasSuffix
(
s
.
GetMainFile
()
,
".pde"
)
{
files
=
append
(
files
,
s
.
GetMainFile
()
)
}
if
len
(
files
)
>
0
{
// .pde files are still supported but deprecated, this warning urges the user to rename them
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment