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
35fb9d31
Commit
35fb9d31
authored
Sep 22, 2018
by
Eduardo Caceres
Committed by
Cristian Maglie
Sep 25, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor style changes in code documentation
parent
f8e52e2e
Changes
31
Hide whitespace changes
Inline
Side-by-side
Showing
31 changed files
with
65 additions
and
65 deletions
+65
-65
arduino/cores/tools.go
arduino/cores/tools.go
+1
-1
builder_client_helpers/alive.go
builder_client_helpers/alive.go
+1
-1
builder_client_helpers/boards.go
builder_client_helpers/boards.go
+2
-2
builder_client_helpers/boards_v2.go
builder_client_helpers/boards_v2.go
+6
-6
builder_client_helpers/compilations.go
builder_client_helpers/compilations.go
+1
-1
builder_client_helpers/examples.go
builder_client_helpers/examples.go
+1
-1
builder_client_helpers/files.go
builder_client_helpers/files.go
+1
-1
builder_client_helpers/libraries.go
builder_client_helpers/libraries.go
+3
-3
builder_client_helpers/pinned_libraries.go
builder_client_helpers/pinned_libraries.go
+6
-6
commands/commands.go
commands/commands.go
+1
-1
commands/generatedocs/generatedocs.go
commands/generatedocs/generatedocs.go
+1
-1
common/formatter/README.adoc
common/formatter/README.adoc
+2
-2
common/formatter/output/common_structs.go
common/formatter/output/common_structs.go
+1
-1
create_client_helpers/alive.go
create_client_helpers/alive.go
+2
-2
create_client_helpers/files.go
create_client_helpers/files.go
+2
-2
create_client_helpers/sketches.go
create_client_helpers/sketches.go
+10
-10
create_client_helpers/user_types.go
create_client_helpers/user_types.go
+1
-1
vendor/github.com/arduino/arduino-builder/ctags/ctags_to_prototypes.go
....com/arduino/arduino-builder/ctags/ctags_to_prototypes.go
+1
-1
vendor/github.com/arduino/arduino-builder/types/context.go
vendor/github.com/arduino/arduino-builder/types/context.go
+1
-1
vendor/github.com/arduino/board-discovery/README.adoc
vendor/github.com/arduino/board-discovery/README.adoc
+1
-1
vendor/github.com/arduino/board-discovery/discovery.go
vendor/github.com/arduino/board-discovery/discovery.go
+3
-3
vendor/github.com/arduino/board-discovery/serial.go
vendor/github.com/arduino/board-discovery/serial.go
+1
-1
vendor/github.com/dimfeld/httptreemux/group.go
vendor/github.com/dimfeld/httptreemux/group.go
+1
-1
vendor/github.com/goadesign/goa/uuid/uuid_js.go
vendor/github.com/goadesign/goa/uuid/uuid_js.go
+2
-2
vendor/github.com/hashicorp/golang-lru/simplelru/lru_interface.go
...ithub.com/hashicorp/golang-lru/simplelru/lru_interface.go
+1
-1
vendor/github.com/oleksandr/bonjour/server.go
vendor/github.com/oleksandr/bonjour/server.go
+1
-1
vendor/github.com/sirupsen/logrus/logger.go
vendor/github.com/sirupsen/logrus/logger.go
+3
-3
vendor/github.com/spf13/pflag/golangflag.go
vendor/github.com/spf13/pflag/golangflag.go
+1
-1
vendor/go.bug.st/serial.v1/enumerator/usb_ole_windows.go
vendor/go.bug.st/serial.v1/enumerator/usb_ole_windows.go
+5
-5
vendor/gopkg.in/cheggaaa/pb.v1/pb.go
vendor/gopkg.in/cheggaaa/pb.v1/pb.go
+1
-1
vendor/gopkg.in/gorethink/gorethink.v3/ql2/ql2.proto
vendor/gopkg.in/gorethink/gorethink.v3/ql2/ql2.proto
+1
-1
No files found.
arduino/cores/tools.go
View file @
35fb9d31
...
...
@@ -30,7 +30,7 @@ import (
// Tool represents a single Tool, part of a Package.
type
Tool
struct
{
Name
string
`json:"name,required"`
// The Name of the Tool.
Releases
map
[
string
]
*
ToolRelease
`json:"releases"`
//Maps Version to Release.
Releases
map
[
string
]
*
ToolRelease
`json:"releases"`
//
Maps Version to Release.
Package
*
Package
`json:"-"`
}
...
...
builder_client_helpers/alive.go
View file @
35fb9d31
...
...
@@ -38,7 +38,7 @@ func (c *Client) PingAlive(ctx context.Context, path string) (*http.Response, er
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewPingAliveRequest create the request corresponding to the ping action endpoint of the alive resource.
// NewPingAliveRequest create
s
the request corresponding to the ping action endpoint of the alive resource.
func
(
c
*
Client
)
NewPingAliveRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
builder_client_helpers/boards.go
View file @
35fb9d31
...
...
@@ -38,7 +38,7 @@ func (c *Client) ListBoards(ctx context.Context, path string) (*http.Response, e
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewListBoardsRequest create the request corresponding to the list action endpoint of the boards resource.
// NewListBoardsRequest create
s
the request corresponding to the list action endpoint of the boards resource.
func
(
c
*
Client
)
NewListBoardsRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -69,7 +69,7 @@ func (c *Client) ShowBoards(ctx context.Context, path string) (*http.Response, e
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewShowBoardsRequest create the request corresponding to the show action endpoint of the boards resource.
// NewShowBoardsRequest create
s
the request corresponding to the show action endpoint of the boards resource.
func
(
c
*
Client
)
NewShowBoardsRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
builder_client_helpers/boards_v2.go
View file @
35fb9d31
...
...
@@ -33,7 +33,7 @@ func ByVidPidBoardsV2Path(vid string, pid string) string {
return
fmt
.
Sprintf
(
"/builder/v2/boards/byVidPid/%s/%s"
,
param0
,
param1
)
}
//
P
rovides the board identified by the :vid and :pid params. Doesn't require authentication.
//
ByVidPidBoardsV2 p
rovides the board identified by the :vid and :pid params. Doesn't require authentication.
func
(
c
*
Client
)
ByVidPidBoardsV2
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewByVidPidBoardsV2Request
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -42,7 +42,7 @@ func (c *Client) ByVidPidBoardsV2(ctx context.Context, path string) (*http.Respo
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewByVidPidBoardsV2Request create the request corresponding to the byVidPid action endpoint of the boards_v2 resource.
// NewByVidPidBoardsV2Request create
s
the request corresponding to the byVidPid action endpoint of the boards_v2 resource.
func
(
c
*
Client
)
NewByVidPidBoardsV2Request
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -62,7 +62,7 @@ func ListBoardsV2Path() string {
return
fmt
.
Sprintf
(
"/builder/v2/boards"
)
}
//
P
rovides a list of all the boards supported by Arduino Create. Doesn't require any authentication.
//
ListBoardsV2 p
rovides a list of all the boards supported by Arduino Create. Doesn't require any authentication.
func
(
c
*
Client
)
ListBoardsV2
(
ctx
context
.
Context
,
path
string
,
limit
*
int
,
offset
*
int
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewListBoardsV2Request
(
ctx
,
path
,
limit
,
offset
)
if
err
!=
nil
{
...
...
@@ -71,7 +71,7 @@ func (c *Client) ListBoardsV2(ctx context.Context, path string, limit *int, offs
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewListBoardsV2Request create the request corresponding to the list action endpoint of the boards_v2 resource.
// NewListBoardsV2Request create
s
the request corresponding to the list action endpoint of the boards_v2 resource.
func
(
c
*
Client
)
NewListBoardsV2Request
(
ctx
context
.
Context
,
path
string
,
limit
*
int
,
offset
*
int
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -102,7 +102,7 @@ func ShowBoardsV2Path(fqbn string) string {
return
fmt
.
Sprintf
(
"/builder/v2/boards/%s"
,
param0
)
}
//
P
rovides the board identified by an fqbn. Doesn't require authentication.
//
ShowBoardsV2 p
rovides the board identified by an fqbn. Doesn't require authentication.
func
(
c
*
Client
)
ShowBoardsV2
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewShowBoardsV2Request
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -111,7 +111,7 @@ func (c *Client) ShowBoardsV2(ctx context.Context, path string) (*http.Response,
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewShowBoardsV2Request create the request corresponding to the show action endpoint of the boards_v2 resource.
// NewShowBoardsV2Request create
s
the request corresponding to the show action endpoint of the boards_v2 resource.
func
(
c
*
Client
)
NewShowBoardsV2Request
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
builder_client_helpers/compilations.go
View file @
35fb9d31
...
...
@@ -42,7 +42,7 @@ func (c *Client) StartCompilations(ctx context.Context, path string, payload *Co
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewStartCompilationsRequest create the request corresponding to the start action endpoint of the compilations resource.
// NewStartCompilationsRequest create
s
the request corresponding to the start action endpoint of the compilations resource.
func
(
c
*
Client
)
NewStartCompilationsRequest
(
ctx
context
.
Context
,
path
string
,
payload
*
Compilation
)
(
*
http
.
Request
,
error
)
{
var
body
bytes
.
Buffer
err
:=
c
.
Encoder
.
Encode
(
payload
,
&
body
,
"*/*"
)
...
...
builder_client_helpers/examples.go
View file @
35fb9d31
...
...
@@ -38,7 +38,7 @@ func (c *Client) ListExamples(ctx context.Context, path string, maintainer *stri
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewListExamplesRequest create the request corresponding to the list action endpoint of the examples resource.
// NewListExamplesRequest create
s
the request corresponding to the list action endpoint of the examples resource.
func
(
c
*
Client
)
NewListExamplesRequest
(
ctx
context
.
Context
,
path
string
,
maintainer
*
string
,
libType
*
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
builder_client_helpers/files.go
View file @
35fb9d31
...
...
@@ -38,7 +38,7 @@ func (c *Client) ShowFiles(ctx context.Context, path string) (*http.Response, er
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewShowFilesRequest create the request corresponding to the show action endpoint of the files resource.
// NewShowFilesRequest create
s
the request corresponding to the show action endpoint of the files resource.
func
(
c
*
Client
)
NewShowFilesRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
builder_client_helpers/libraries.go
View file @
35fb9d31
...
...
@@ -42,7 +42,7 @@ func (c *Client) ListLibraries(
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewListLibrariesRequest create the request corresponding to the list action endpoint of the libraries resource.
// NewListLibrariesRequest create
s
the request corresponding to the list action endpoint of the libraries resource.
func
(
c
*
Client
)
NewListLibrariesRequest
(
ctx
context
.
Context
,
path
string
,
maintainer
*
string
,
libType
*
string
,
withoutType
*
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -73,7 +73,7 @@ func ShowLibrariesPath(id string) string {
}
// ShowLibraries provides the library identified by the :id and :pid param. Doesn't require authentication.
// Also contains a list of other versions of the library
// Also contains a list of other versions of the library
.
func
(
c
*
Client
)
ShowLibraries
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewShowLibrariesRequest
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -82,7 +82,7 @@ func (c *Client) ShowLibraries(ctx context.Context, path string) (*http.Response
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewShowLibrariesRequest create the request corresponding to the show action endpoint of the libraries resource.
// NewShowLibrariesRequest create
s
the request corresponding to the show action endpoint of the libraries resource.
func
(
c
*
Client
)
NewShowLibrariesRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
builder_client_helpers/pinned_libraries.go
View file @
35fb9d31
...
...
@@ -31,7 +31,7 @@ func AddPinnedLibrariesPath(id string) string {
return
fmt
.
Sprintf
(
"/builder/pinned/%s"
,
param0
)
}
//AddPinnedLibraries adds a new library to the list of libraries pinned by the user
//
AddPinnedLibraries adds a new library to the list of libraries pinned by the user
func
(
c
*
Client
)
AddPinnedLibraries
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewAddPinnedLibrariesRequest
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -40,7 +40,7 @@ func (c *Client) AddPinnedLibraries(ctx context.Context, path string) (*http.Res
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewAddPinnedLibrariesRequest create the request
// NewAddPinnedLibrariesRequest create
s
the request
// corresponding to the add action endpoint of the pinnedLibraries resource.
func
(
c
*
Client
)
NewAddPinnedLibrariesRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
...
...
@@ -63,7 +63,7 @@ func ListPinnedLibrariesPath() string {
return
fmt
.
Sprintf
(
"/builder/pinned"
)
}
//ListPinnedLibraries provides a list of all the libraries pinned by the user
//
ListPinnedLibraries provides a list of all the libraries pinned by the user
func
(
c
*
Client
)
ListPinnedLibraries
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewListPinnedLibrariesRequest
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -72,7 +72,7 @@ func (c *Client) ListPinnedLibraries(ctx context.Context, path string) (*http.Re
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewListPinnedLibrariesRequest create the request corresponding to the list action endpoint of the pinnedLibraries resource.
// NewListPinnedLibrariesRequest create
s
the request corresponding to the list action endpoint of the pinnedLibraries resource.
func
(
c
*
Client
)
NewListPinnedLibrariesRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -96,7 +96,7 @@ func RemovePinnedLibrariesPath(id string) string {
return
fmt
.
Sprintf
(
"/builder/pinned/%s"
,
param0
)
}
//RemovePinnedLibraries removes a library to the list of libraries pinned by the user
//
RemovePinnedLibraries removes a library to the list of libraries pinned by the user
func
(
c
*
Client
)
RemovePinnedLibraries
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewRemovePinnedLibrariesRequest
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -105,7 +105,7 @@ func (c *Client) RemovePinnedLibraries(ctx context.Context, path string) (*http.
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewRemovePinnedLibrariesRequest create the request corresponding to the remove action endpoint of the pinnedLibraries resource.
// NewRemovePinnedLibrariesRequest create
s
the request corresponding to the remove action endpoint of the pinnedLibraries resource.
func
(
c
*
Client
)
NewRemovePinnedLibrariesRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
commands/commands.go
View file @
35fb9d31
...
...
@@ -105,7 +105,7 @@ func InitPackageManager() *packagemanager.PackageManager {
return
pm
}
// InitLibraryManager initialize the LibraryManager using the underlying packagemanager
// InitLibraryManager initialize
s
the LibraryManager using the underlying packagemanager
func
InitLibraryManager
(
pm
*
packagemanager
.
PackageManager
)
*
librariesmanager
.
LibrariesManager
{
logrus
.
Info
(
"Starting libraries manager"
)
lm
:=
librariesmanager
.
NewLibraryManager
(
...
...
commands/generatedocs/generatedocs.go
View file @
35fb9d31
...
...
@@ -65,7 +65,7 @@ func generateBashCompletions(cmd *cobra.Command, args []string) {
}
}
// Generate man pages for all commands and puts them in $PROJECT_DIR/docs/manpages.
// Generate
s
man pages for all commands and puts them in $PROJECT_DIR/docs/manpages.
func
generateManPages
(
cmd
*
cobra
.
Command
,
args
[]
string
)
{
if
outputDir
==
""
{
outputDir
=
"docs/manpages"
...
...
common/formatter/README.adoc
View file @
35fb9d31
...
...
@@ -27,11 +27,11 @@ var test TestType{
var testString = a.Format(test)
fmt.Println(testString) // Prints test.String()
a.Print(test) //
d
oes the same.
a.Print(test) //
D
oes the same.
testString = b.Format(test)
fmt.Println(testString) // Prints { field1 : "test", field2 : "42" }
b.Print(test) //Does the same
b.Print(test) //
Does the same
----
=== The default formatter
...
...
common/formatter/output/common_structs.go
View file @
35fb9d31
...
...
@@ -22,7 +22,7 @@ import (
"strings"
)
//ProcessResult contains info about a completed process.
//
ProcessResult contains info about a completed process.
type
ProcessResult
struct
{
ItemName
string
`json:"name,required"`
Status
string
`json:"status,omitempty"`
...
...
create_client_helpers/alive.go
View file @
35fb9d31
...
...
@@ -30,7 +30,7 @@ func PingAlivePath() string {
return
fmt
.
Sprintf
(
"/create/alive"
)
}
// Returns 200 if the instance is healthy
// Returns 200 if the instance is healthy
.
func
(
c
*
Client
)
PingAlive
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewPingAliveRequest
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -39,7 +39,7 @@ func (c *Client) PingAlive(ctx context.Context, path string) (*http.Response, er
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewPingAliveRequest create the request corresponding to the ping action endpoint of the alive resource.
// NewPingAliveRequest create
s
the request corresponding to the ping action endpoint of the alive resource.
func
(
c
*
Client
)
NewPingAliveRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
create_client_helpers/files.go
View file @
35fb9d31
...
...
@@ -33,7 +33,7 @@ func ShowFilesPath(fileType string, id string, name string) string {
return
fmt
.
Sprintf
(
"/create/v1/files/%s/%s/%s"
,
param0
,
param1
,
param2
)
}
//
Provides the content of the file identified by :name and :id
//
ShowFiles provides the content of the file identified by :name and :id.
func
(
c
*
Client
)
ShowFiles
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewShowFilesRequest
(
ctx
,
path
)
if
err
!=
nil
{
...
...
@@ -42,7 +42,7 @@ func (c *Client) ShowFiles(ctx context.Context, path string) (*http.Response, er
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewShowFilesRequest create the request corresponding to the show action endpoint of the files resource.
// NewShowFilesRequest create
s
the request corresponding to the show action endpoint of the files resource.
func
(
c
*
Client
)
NewShowFilesRequest
(
ctx
context
.
Context
,
path
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
create_client_helpers/sketches.go
View file @
35fb9d31
...
...
@@ -36,7 +36,7 @@ const (
prod
=
true
)
// CreateSketches
A
dds a new sketch.
// CreateSketches
a
dds a new sketch.
func
(
c
*
Client
)
CreateSketches
(
ctx
context
.
Context
,
path
string
,
payload
*
Sketch
,
authorization
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewCreateSketchesRequest
(
ctx
,
path
,
payload
,
authorization
)
if
err
!=
nil
{
...
...
@@ -45,7 +45,7 @@ func (c *Client) CreateSketches(ctx context.Context, path string, payload *Sketc
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewCreateSketchesRequest create the request corresponding to the create action endpoint of the sketches resource.
// NewCreateSketchesRequest create
s
the request corresponding to the create action endpoint of the sketches resource.
func
(
c
*
Client
)
NewCreateSketchesRequest
(
ctx
context
.
Context
,
path
string
,
payload
*
Sketch
,
authorization
string
)
(
*
http
.
Request
,
error
)
{
var
body
bytes
.
Buffer
err
:=
c
.
Encoder
.
Encode
(
payload
,
&
body
,
"*/*"
)
...
...
@@ -79,7 +79,7 @@ func DeleteSketchesPath(id string) string {
return
fmt
.
Sprintf
(
"/create/v1/sketches/%s"
,
id
)
}
// DeleteSketches
R
emoves the sketch identified by the :id param.
// DeleteSketches
r
emoves the sketch identified by the :id param.
func
(
c
*
Client
)
DeleteSketches
(
ctx
context
.
Context
,
path
string
,
authorization
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewDeleteSketchesRequest
(
ctx
,
path
,
authorization
)
if
err
!=
nil
{
...
...
@@ -88,7 +88,7 @@ func (c *Client) DeleteSketches(ctx context.Context, path string, authorization
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewDeleteSketchesRequest create the request corresponding to the delete action endpoint of the sketches resource.
// NewDeleteSketchesRequest create
s
the request corresponding to the delete action endpoint of the sketches resource.
func
(
c
*
Client
)
NewDeleteSketchesRequest
(
ctx
context
.
Context
,
path
string
,
authorization
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -118,7 +118,7 @@ func EditSketchesPath(id string) string {
return
fmt
.
Sprintf
(
"/create/v1/sketches/%s"
,
param0
)
}
// EditSketches
M
odifies the sketch identified by the :id param.
// EditSketches
m
odifies the sketch identified by the :id param.
// If a file has a valid data field, it will be modified too.
func
(
c
*
Client
)
EditSketches
(
ctx
context
.
Context
,
path
string
,
payload
*
Sketch
,
authorization
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewEditSketchesRequest
(
ctx
,
path
,
payload
,
authorization
)
...
...
@@ -128,7 +128,7 @@ func (c *Client) EditSketches(ctx context.Context, path string, payload *Sketch,
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewEditSketchesRequest create the request corresponding to the edit action endpoint of the sketches resource.
// NewEditSketchesRequest create
s
the request corresponding to the edit action endpoint of the sketches resource.
func
(
c
*
Client
)
NewEditSketchesRequest
(
ctx
context
.
Context
,
path
string
,
payload
*
Sketch
,
authorization
string
)
(
*
http
.
Request
,
error
)
{
var
body
bytes
.
Buffer
err
:=
c
.
Encoder
.
Encode
(
payload
,
&
body
,
"*/*"
)
...
...
@@ -162,7 +162,7 @@ func SearchSketchesPath() string {
return
fmt
.
Sprintf
(
"/create/v1/sketches"
)
}
// SearchSketches
P
rovides a paginated list of sketches filtered according to the params. The page size is 100 items.
// SearchSketches
p
rovides a paginated list of sketches filtered according to the params. The page size is 100 items.
func
(
c
*
Client
)
SearchSketches
(
ctx
context
.
Context
,
path
string
,
offset
*
string
,
owner
*
string
,
authorization
*
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewSearchSketchesRequest
(
ctx
,
path
,
offset
,
owner
,
authorization
)
if
err
!=
nil
{
...
...
@@ -171,7 +171,7 @@ func (c *Client) SearchSketches(ctx context.Context, path string, offset *string
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewSearchSketchesRequest create the request corresponding to the search action endpoint of the sketches resource.
// NewSearchSketchesRequest create
s
the request corresponding to the search action endpoint of the sketches resource.
func
(
c
*
Client
)
NewSearchSketchesRequest
(
ctx
context
.
Context
,
path
string
,
offset
*
string
,
owner
*
string
,
authorization
*
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
@@ -209,7 +209,7 @@ func ShowSketchesPath(id string) string {
return
fmt
.
Sprintf
(
"/create/v1/sketches/%s"
,
param0
)
}
// ShowSketches
P
rovides the sketch identified by the :id param.
// ShowSketches
p
rovides the sketch identified by the :id param.
func
(
c
*
Client
)
ShowSketches
(
ctx
context
.
Context
,
path
string
,
authorization
*
string
)
(
*
http
.
Response
,
error
)
{
req
,
err
:=
c
.
NewShowSketchesRequest
(
ctx
,
path
,
authorization
)
if
err
!=
nil
{
...
...
@@ -218,7 +218,7 @@ func (c *Client) ShowSketches(ctx context.Context, path string, authorization *s
return
c
.
Client
.
Do
(
ctx
,
req
)
}
// NewShowSketchesRequest create the request corresponding to the show action endpoint of the sketches resource.
// NewShowSketchesRequest create
s
the request corresponding to the show action endpoint of the sketches resource.
func
(
c
*
Client
)
NewShowSketchesRequest
(
ctx
context
.
Context
,
path
string
,
authorization
*
string
)
(
*
http
.
Request
,
error
)
{
scheme
:=
c
.
Scheme
if
scheme
==
""
{
...
...
create_client_helpers/user_types.go
View file @
35fb9d31
...
...
@@ -54,7 +54,7 @@ type Sketch struct {
Types
[]
string
`form:"types,omitempty" json:"types,omitempty" xml:"types,omitempty"`
}
//ConvertFrom converts from a local sketch to an Arduino Create sketch.
//
ConvertFrom converts from a local sketch to an Arduino Create sketch.
func
ConvertFrom
(
sketch
sketches
.
Sketch
)
*
Sketch
{
_
,
inoPath
:=
filepath
.
Split
(
sketch
.
Ino
.
Path
)
content
,
err
:=
ioutil
.
ReadFile
(
filepath
.
Join
(
sketch
.
FullPath
,
inoPath
))
...
...
vendor/github.com/arduino/arduino-builder/ctags/ctags_to_prototypes.go
View file @
35fb9d31
...
...
@@ -112,7 +112,7 @@ func (p *CTagsParser) toPrototypes() []*types.Prototype {
Prototype
:
tag
.
Prototype
,
Modifiers
:
tag
.
PrototypeModifiers
,
Line
:
tag
.
Line
,
//Fields: tag,
//
Fields: tag,
}
prototypes
=
append
(
prototypes
,
prototype
)
}
...
...
vendor/github.com/arduino/arduino-builder/types/context.go
View file @
35fb9d31
...
...
@@ -79,7 +79,7 @@ type Context struct {
ImportedLibraries
libraries
.
List
LibrariesResolutionResults
map
[
string
]
LibraryResolutionResult
IncludeFolders
paths
.
PathList
//OutputGccMinusM string
//
OutputGccMinusM string
// C++ Parsing
CTagsOutput
string
...
...
vendor/github.com/arduino/board-discovery/README.adoc
View file @
35fb9d31
...
...
@@ -26,7 +26,7 @@ Then start, get data and stop it when you don't need it anymore:
[source, go]
----
monitor.Start()
//Get devices connected
//
Get devices connected
monitor.Stop()
----
You can get connected devices (via Serial or Network ports) by using the following functions:
...
...
vendor/github.com/arduino/board-discovery/discovery.go
View file @
35fb9d31
...
...
@@ -71,7 +71,7 @@ type SerialDevice struct {
SerialNumber
string
`json:"serial_number"`
ProductID
string
`json:"pid"`
VendorID
string
`json:"vid"`
//Serial *serial.Info `json:"-"`
//
Serial *serial.Info `json:"-"`
}
func
(
d
SerialDevice
)
String
()
string
{
...
...
@@ -85,7 +85,7 @@ func (d SerialDevice) String() string {
return
ret
}
//SerialDevices is a list of currently connected devices to the computer
//
SerialDevices is a list of currently connected devices to the computer
type
SerialDevices
map
[
string
]
*
SerialDevice
func
(
sds
SerialDevices
)
String
()
string
{
...
...
@@ -124,7 +124,7 @@ func (d NetworkDevice) String() string {
fmt
.
Sprintln
(
" PORT:"
,
d
.
Port
)
}
//NetworkDevices is a list of currently connected devices to the computer
//
NetworkDevices is a list of currently connected devices to the computer
type
NetworkDevices
map
[
string
]
*
NetworkDevice
func
(
nds
NetworkDevices
)
String
()
string
{
...
...
vendor/github.com/arduino/board-discovery/serial.go
View file @
35fb9d31
...
...
@@ -88,7 +88,7 @@ func (m *Monitor) addSerial(port *enumerator.PortDetails) {
SerialNumber
:
port
.
SerialNumber
,
ProductID
:
"0x"
+
port
.
PID
,
VendorID
:
"0x"
+
port
.
VID
,
//Serial: port,
//
Serial: port,
}
for
port
,
dev
:=
range
m
.
serial
{
if
port
==
device
.
Port
{
...
...
vendor/github.com/dimfeld/httptreemux/group.go
View file @
35fb9d31
...
...
@@ -19,7 +19,7 @@ func (g *Group) NewGroup(path string) *Group {
checkPath
(
path
)
path
=
g
.
path
+
path
//Don't want trailing slash as all sub-paths start with slash
//
Don't want trailing slash as all sub-paths start with slash
if
path
[
len
(
path
)
-
1
]
==
'/'
{
path
=
path
[
:
len
(
path
)
-
1
]
}
...
...
vendor/github.com/goadesign/goa/uuid/uuid_js.go
View file @
35fb9d31
// +build js
//This part is copied from github.com/satori/go.uuid but some feature uses non gopherjs compliants calls
//Since goa only needs a subset of the features the js copies them in here
//
This part is copied from github.com/satori/go.uuid but some feature uses non gopherjs compliants calls
//
Since goa only needs a subset of the features the js copies them in here
package
uuid
...
...
vendor/github.com/hashicorp/golang-lru/simplelru/lru_interface.go
View file @
35fb9d31
...
...
@@ -11,7 +11,7 @@ type LRUCache interface {
// updates the "recently used"-ness of the key. #value, isFound
Get
(
key
interface
{})
(
value
interface
{},
ok
bool
)
// Check
if a key exs
ists in cache without updating the recent-ness.
// Check
s if a key ex
ists in cache without updating the recent-ness.
Contains
(
key
interface
{})
(
ok
bool
)
// Returns key's value without updating the "recently used"-ness of the key.
...
...
vendor/github.com/oleksandr/bonjour/server.go
View file @
35fb9d31
...
...
@@ -510,7 +510,7 @@ func (s *Server) serviceTypeName(resp *dns.Msg, ttl uint32) {
}
// Perform probing & announcement
//TODO: implement a proper probing & conflict resolution
//
TODO: implement a proper probing & conflict resolution
func
(
s
*
Server
)
probe
()
{
q
:=
new
(
dns
.
Msg
)
q
.
SetQuestion
(
s
.
service
.
ServiceInstanceName
(),
dns
.
TypePTR
)
...
...
vendor/github.com/sirupsen/logrus/logger.go
View file @
35fb9d31
...
...
@@ -301,9 +301,9 @@ func (logger *Logger) Panicln(args ...interface{}) {
}
}
//When file is opened with appending mode, it's safe to
//write concurrently to a file (within 4k message on Linux).
//In these cases user can choose to disable the lock.
//
When file is opened with appending mode, it's safe to
//
write concurrently to a file (within 4k message on Linux).
//
In these cases user can choose to disable the lock.
func
(
logger
*
Logger
)
SetNoLock
()
{
logger
.
mu
.
Disable
()
}
...
...
vendor/github.com/spf13/pflag/golangflag.go
View file @
35fb9d31
...
...
@@ -68,7 +68,7 @@ func PFlagFromGoFlag(goflag *goflag.Flag) *Flag {
Usage
:
goflag
.
Usage
,
Value
:
wrapFlagValue
(
goflag
.
Value
),
// Looks like golang flags don't set DefValue correctly :-(
//DefValue: goflag.DefValue,
//
DefValue: goflag.DefValue,
DefValue
:
goflag
.
Value
.
String
(),
}
// Ex: if the golang flag was -v, allow both -v and --v to work
...
...
vendor/go.bug.st/serial.v1/enumerator/usb_ole_windows.go
View file @
35fb9d31
...
...
@@ -92,11 +92,11 @@ func getPortDetails(item *ole.IDispatch, res *PortDetails) error {
}
res
.
Name
=
re
[
0
][
1
]
//itemPnPDeviceID, err := item.GetProperty("PnPDeviceID")
//if err != nil {
// return err
//}
//PnPDeviceID := itemPnPDeviceID.ToString()
//
itemPnPDeviceID, err := item.GetProperty("PnPDeviceID")
//
if err != nil {
//
return err
//
}
//
PnPDeviceID := itemPnPDeviceID.ToString()
itemDeviceID
,
err
:=
item
.
GetProperty
(
"DeviceID"
)
if
err
!=
nil
{
...
...
vendor/gopkg.in/cheggaaa/pb.v1/pb.go
View file @
35fb9d31
...
...
@@ -229,7 +229,7 @@ func (pb *ProgressBar) SetWidth(width int) *ProgressBar {
// End print
func
(
pb
*
ProgressBar
)
Finish
()
{
//Protect multiple calls
//
Protect multiple calls
pb
.
finishOnce
.
Do
(
func
()
{
close
(
pb
.
finish
)
pb
.
write
(
atomic
.
LoadInt64
(
&
pb
.
Total
),
atomic
.
LoadInt64
(
&
pb
.
current
))
...
...
vendor/gopkg.in/gorethink/gorethink.v3/ql2/ql2.proto
View file @
35fb9d31
...
...
@@ -362,7 +362,7 @@ message Term {
APPEND
=
29
;
// ARRAY, DATUM -> ARRAY
// Prepend a single element to the end of an array (like `cons`).
PREPEND
=
80
;
// ARRAY, DATUM -> ARRAY
//Remove the elements of one array from another array.
//
Remove the elements of one array from another array.
DIFFERENCE
=
95
;
// ARRAY, ARRAY -> ARRAY
// DATUM Set Ops
...
...
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