Skip to content

Update module name in go.mod #91

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
Jun 7, 2021
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
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ deps: deps-go

gen: ./osquery.thrift
mkdir -p ./gen
thrift --gen go:package_prefix=github.com/kolide/osquery-go/gen/ -out ./gen ./osquery.thrift
thrift --gen go:package_prefix=github.com/osquery/osquery-go/gen/ -out ./gen ./osquery.thrift
rm -rf gen/osquery/extension-remote gen/osquery/extension_manager-remote
gofmt -w ./gen

Expand Down
21 changes: 8 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# osquery-go

[![CircleCI](https://circleci.com/gh/kolide/osquery-go/tree/master.svg?style=svg)](https://circleci.com/gh/kolide/osquery-go/tree/master)
[![GoDoc](https://godoc.org/github.com/kolide/osquery-go?status.svg)](http://godoc.org/github.com/kolide/osquery-go)
[![CircleCI](https://circleci.com/gh/osquery/osquery-go/tree/master.svg?style=svg)](https://circleci.com/gh/osquery/osquery-go/tree/master)
[![GoDoc](https://godoc.org/github.com/osquery/osquery-go?status.svg)](http://godoc.org/github.com/osquery/osquery-go)

[osquery](https://github.com/facebook/osquery) exposes an operating system as a high-performance relational database. This allows you to write SQL-based queries to explore operating system data. With osquery, SQL tables represent abstract concepts such as running processes, loaded kernel modules, open network connections, browser plugins, hardware events or file hashes.

Expand All @@ -13,16 +13,11 @@ In osquery, SQL tables, configuration retrieval, log handling, etc. are implemen

## Install

To install this library in your `GOPATH`:
This library is compatible with Go Modules. To install:

``` go
go get github.com/osquery/osquery-go
```
mkdir -p $GOPATH/src/github.com/kolide/
git clone [email protected]:kolide/osquery-go.git $GOPATH/src/github.com/kolide/osquery-go
cd $GOPATH/src/github.com/kolide/osquery-go
make deps
```

Alternatively, if you're using this in a project that uses a dependency management tool like [Glide](https://github.com/Masterminds/glide) or [Dep](https://github.com/golang/dep), then follow the relevant instructions provided by that tool.

## Using the library

Expand All @@ -40,8 +35,8 @@ import (
"os"
"flag"

"github.com/kolide/osquery-go"
"github.com/kolide/osquery-go/plugin/table"
"github.com/osquery/osquery-go"
"github.com/osquery/osquery-go/plugin/table"
)

func main() {
Expand Down Expand Up @@ -194,7 +189,7 @@ import (
"os"
"time"

"github.com/kolide/osquery-go"
"github.com/osquery/osquery-go"
)

func main() {
Expand Down
4 changes: 2 additions & 2 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"context"
"time"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/kolide/osquery-go/transport"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/transport"
"github.com/pkg/errors"

"github.com/apache/thrift/lib/go/thrift"
Expand Down
4 changes: 2 additions & 2 deletions client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"errors"
"testing"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/kolide/osquery-go/mock"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/mock"
"github.com/stretchr/testify/assert"
)

Expand Down
2 changes: 1 addition & 1 deletion examples/call/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"
"time"

"github.com/kolide/osquery-go"
"github.com/osquery/osquery-go"
)

func main() {
Expand Down
4 changes: 2 additions & 2 deletions examples/config/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"log"
"time"

"github.com/kolide/osquery-go"
"github.com/kolide/osquery-go/plugin/config"
"github.com/osquery/osquery-go"
"github.com/osquery/osquery-go/plugin/config"
)

var (
Expand Down
4 changes: 2 additions & 2 deletions examples/distributed/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"fmt"
"log"

"github.com/kolide/osquery-go"
"github.com/kolide/osquery-go/plugin/distributed"
"github.com/osquery/osquery-go"
"github.com/osquery/osquery-go/plugin/distributed"
)

func main() {
Expand Down
4 changes: 2 additions & 2 deletions examples/logger/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"flag"
"log"

"github.com/kolide/osquery-go"
"github.com/kolide/osquery-go/plugin/logger"
"github.com/osquery/osquery-go"
"github.com/osquery/osquery-go/plugin/logger"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion examples/query/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"
"time"

"github.com/kolide/osquery-go"
"github.com/osquery/osquery-go"
)

func main() {
Expand Down
4 changes: 2 additions & 2 deletions examples/table/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"log"
"time"

"github.com/kolide/osquery-go"
"github.com/kolide/osquery-go/plugin/table"
"github.com/osquery/osquery-go"
"github.com/osquery/osquery-go/plugin/table"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
module github.com/kolide/osquery-go
module github.com/osquery/osquery-go

require (
github.com/Microsoft/go-winio v0.4.9
github.com/apache/thrift v0.13.1-0.20200603211036-eac4d0c79a5f
github.com/davecgh/go-spew v1.1.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/pkg/errors v0.8.0
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/stretchr/testify v1.2.2
golang.org/x/sys v0.0.0-20180815093151-14742f9018cd // indirect
golang.org/x/sys v0.0.0-20210603125802-9665404d3644 // indirect
)

go 1.13
10 changes: 4 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
github.com/Microsoft/go-winio v0.4.9 h1:3RbgqgGVqmcpbOiwrjbVtDHLlJBGF6aE+yHmNtBNsFQ=
github.com/Microsoft/go-winio v0.4.9/go.mod h1:VhR8bwka0BXejwEJY73c50VrPtXAaKcyvVC4A4RozmA=
github.com/apache/thrift v0.13.0 h1:5hryIiq9gtn+MiLVn0wP37kb/uTeRZgN08WoCsAhIhI=
github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/apache/thrift v0.13.1-0.20200603211036-eac4d0c79a5f h1:33BV5v3u8I6dA2dEoPuXWCsAaHHOJfPtdxZhAMQV4uo=
github.com/apache/thrift v0.13.1-0.20200603211036-eac4d0c79a5f/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/pkg/errors v0.8.0 h1:WdK/asTD0HN+q6hsWO3/vpuAkAr+tw6aNJNDFFf0+qw=
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/testify v1.2.2 h1:bSDNvY7ZPG5RlJ8otE/7V6gMiyenm9RtJ7IUVIAoJ1w=
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
golang.org/x/sys v0.0.0-20180815093151-14742f9018cd h1:Vdp9FdQnZJQQF78wgpudgkchp80Nu37AWr8+mprtgAo=
golang.org/x/sys v0.0.0-20180815093151-14742f9018cd/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20210603125802-9665404d3644 h1:CA1DEQ4NdKphKeL70tvsWNdT5oFh1lOjihRcEDROi0I=
golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
2 changes: 1 addition & 1 deletion mock/osquery.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package mock
import (
"context"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
)

var _ osquery.ExtensionManager = (*ExtensionManager)(nil)
Expand Down
2 changes: 1 addition & 1 deletion mock_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

package osquery

import "github.com/kolide/osquery-go/gen/osquery"
import "github.com/osquery/osquery-go/gen/osquery"

var _ ExtensionManager = (*MockExtensionManager)(nil)

Expand Down
2 changes: 1 addition & 1 deletion plugin/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ package config
import (
"context"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
)

// GenerateConfigsFunc returns the configurations generated by this plugin.
Expand Down
2 changes: 1 addition & 1 deletion plugin/config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"errors"
"testing"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/stretchr/testify/assert"
)

Expand Down
2 changes: 1 addition & 1 deletion plugin/distributed/distributed.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"strconv"
"strings"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
)

// GetQueriesResult contains the information about which queries the
Expand Down
2 changes: 1 addition & 1 deletion plugin/distributed/distributed_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
"sort"
"testing"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
Expand Down
2 changes: 1 addition & 1 deletion plugin/logger/logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"context"
"encoding/json"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
)

// LogFunc is the logger function used by an osquery Logger plugin.
Expand Down
2 changes: 1 addition & 1 deletion plugin/logger/logger_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"errors"
"testing"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/stretchr/testify/assert"
)

Expand Down
2 changes: 1 addition & 1 deletion plugin/table/table.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"encoding/json"
"strconv"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/pkg/errors"
)

Expand Down
2 changes: 1 addition & 1 deletion plugin/table/table_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"errors"
"testing"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
Expand Down
4 changes: 2 additions & 2 deletions server.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (

"github.com/apache/thrift/lib/go/thrift"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/kolide/osquery-go/transport"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/transport"
"github.com/pkg/errors"
)

Expand Down
4 changes: 2 additions & 2 deletions server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ import (

"github.com/apache/thrift/lib/go/thrift"

"github.com/kolide/osquery-go/gen/osquery"
"github.com/kolide/osquery-go/plugin/logger"
"github.com/osquery/osquery-go/gen/osquery"
"github.com/osquery/osquery-go/plugin/logger"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
Expand Down