Skip to content

Commit

Permalink
Add go module support
Browse files Browse the repository at this point in the history
Signed-off-by: Sascha Grunert <[email protected]>
  • Loading branch information
saschagrunert committed Nov 4, 2019
1 parent d3cd4ed commit 282bb4a
Show file tree
Hide file tree
Showing 14 changed files with 20 additions and 21 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
test_bins
6 changes: 2 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ services:

language: go
go:
- "1.10.x"
- "1.11.x"
- "1.12.x"
- "1.13.x"
go_import_path: github.com/coreos/go-systemd

env:
Expand All @@ -23,8 +23,6 @@ env:
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y libsystemd-journal-dev libsystemd-daemon-dev
- curl https://raw.githubusercontent.com/golang/dep/master/install.sh | INSTALL_DIRECTORY=${DEP_BINDIR} sh
- ${DEP_BINDIR}/dep ensure -v
- docker pull ${DOCKER_BASE}
- docker run --privileged -e GOPATH=${GOPATH} --cidfile=/tmp/cidfile ${DOCKER_BASE} /bin/bash -c "apt-get update && apt-get install -y sudo build-essential git golang dbus libsystemd-dev libpam-systemd systemd-container"
- docker commit `cat /tmp/cidfile` go-systemd/container-tests
Expand Down
7 changes: 0 additions & 7 deletions Gopkg.toml

This file was deleted.

2 changes: 1 addition & 1 deletion dbus/dbus.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
"strings"
"sync"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion dbus/methods.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"path"
"strconv"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

func (c *Conn) jobComplete(signal *dbus.Signal) {
Expand Down
2 changes: 1 addition & 1 deletion dbus/methods_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import (
"testing"
"time"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

type TrUnitProp struct {
Expand Down
4 changes: 2 additions & 2 deletions dbus/properties.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
package dbus

import (
"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

// From the systemd docs:
Expand Down Expand Up @@ -56,7 +56,7 @@ type execStart struct {
// http://www.freedesktop.org/software/systemd/man/systemd.service.html#ExecStart=
func PropExecStart(command []string, uncleanIsFailure bool) Property {
execStarts := []execStart{
execStart{
{
Path: command[0],
Args: command,
UncleanIsFailure: uncleanIsFailure,
Expand Down
2 changes: 1 addition & 1 deletion dbus/subscription.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
"log"
"time"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

const (
Expand Down
5 changes: 5 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module github.com/coreos/go-systemd

go 1.12

require github.com/godbus/dbus/v5 v5.0.3
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
github.com/godbus/dbus/v5 v5.0.3 h1:ZqHaoEF7TBzh4jzPmqVhE/5A1z9of6orkAe5uHoAeME=
github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
2 changes: 1 addition & 1 deletion import1/dbus.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"strconv"
"strings"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion login1/dbus.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"os"
"strconv"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion machine1/dbus.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
"strconv"
"syscall"

"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"

sd_dbus "github.com/coreos/go-systemd/dbus"
)
Expand Down
2 changes: 1 addition & 1 deletion machine1/dbus_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import (
"time"

sd_dbus "github.com/coreos/go-systemd/dbus"
"github.com/godbus/dbus"
"github.com/godbus/dbus/v5"
)

const (
Expand Down

0 comments on commit 282bb4a

Please sign in to comment.