Skip to content

Update readme #207

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

Merged
merged 2 commits into from
Feb 13, 2018
Merged
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
21 changes: 12 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,9 @@ Once you have the websocket endpoint you need you can:
```javascript
var socket = io(endpoint);
socket.on('connect', function () {
socket.emit('message', yourCommand);
socket.emit('command', yourCommand);

socket.on('message', function () {
socket.on('command', function () {
// Your code to handle messages
})
}
Expand Down Expand Up @@ -309,17 +309,20 @@ The results of the upload will be delivered via websocket with messages that loo

## Development

From the project root dir executing:
To clone the repository, run the following command:
```
export GOPATH=$PWD
go get
go build
go get github.com/arduino/arduino-create-agent
```
will build the `arduino-create-agent` binary.

`compile_webidebridge.sh` contains the cross-platform script we use to deploy the agent for all the supported platforms; it needs to be adjusted as per your `go` installation paths and OS.
This will clone the repository into your [Go workspace](https://golang.org/doc/code.html#Workspaces) or create a new workspace, if one doesn't exist. You can set `$GOPATH` to define where your Go workspace is located.

Now you can go to the project directory and compile it:
```
cd $GOPATH/src/github.com/arduino/arduino-create-agent
go build
```

You can use `bootstrapPlatforms` function to compile the needed CGO-enabled environment
This will create the `arduino-create-agent` binary.

Other prerequisites are:
* libappindicator (Linux only on Ubuntu `sudo apt-get install libappindicator1`)
Expand Down