Skip to content

Commit

Permalink
Merge pull request #78 from nlnwa/fix/v2
Browse files Browse the repository at this point in the history
Fix go module v2
  • Loading branch information
maeb authored Oct 31, 2024
2 parents e72241c + b5a6984 commit 2cff962
Show file tree
Hide file tree
Showing 12 changed files with 31 additions and 58 deletions.
39 changes: 0 additions & 39 deletions .github/workflows/lint.yml

This file was deleted.

19 changes: 14 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,24 @@
name: test

on:
pull_request: { }
on: push

jobs:
test:
name: go test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
- uses: actions/setup-go@v5
with:
go-version: '^1.19.0'
go-version: 'stable'
- run: go test ./...
lint:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: 'stable'
- uses: golangci/golangci-lint-action@v6
with:
version: 'latest'
2 changes: 1 addition & 1 deletion block.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"errors"
"io"

"github.com/nlnwa/gowarc/internal/diskbuffer"
"github.com/nlnwa/gowarc/v2/internal/diskbuffer"
)

// Block is the interface used to represent the content of a WARC record as specified by the WARC specification:
Expand Down
7 changes: 4 additions & 3 deletions block_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,14 @@
package gowarc

import (
"github.com/nlnwa/gowarc/internal/diskbuffer"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"io"
"strings"
"testing"
"testing/iotest"

"github.com/nlnwa/gowarc/v2/internal/diskbuffer"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)

func Test_genericBlock_BlockDigest(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion example_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import (
"fmt"
"io"

"github.com/nlnwa/gowarc"
"github.com/nlnwa/gowarc/v2"
)

func ExampleNewRecordBuilder() {
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/nlnwa/gowarc
module github.com/nlnwa/gowarc/v2

go 1.22.0

Expand Down
2 changes: 1 addition & 1 deletion httpblock.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
"io"
"net/http"

"github.com/nlnwa/gowarc/internal/diskbuffer"
"github.com/nlnwa/gowarc/v2/internal/diskbuffer"
)

type HttpRequestBlock interface {
Expand Down
3 changes: 2 additions & 1 deletion internal/timestamp/timestamp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,10 @@
package timestamp_test

import (
"github.com/nlnwa/gowarc/internal/timestamp"
"testing"
"time"

"github.com/nlnwa/gowarc/v2/internal/timestamp"
)

type TestData struct {
Expand Down
2 changes: 1 addition & 1 deletion options.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package gowarc

import (
"github.com/google/uuid"
"github.com/nlnwa/gowarc/internal/diskbuffer"
"github.com/nlnwa/gowarc/v2/internal/diskbuffer"
)

type warcRecordOptions struct {
Expand Down
3 changes: 2 additions & 1 deletion recordbuilder.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,10 @@
package gowarc

import (
"github.com/nlnwa/gowarc/internal/diskbuffer"
"io"
"time"

"github.com/nlnwa/gowarc/v2/internal/diskbuffer"
)

type WarcRecordBuilder interface {
Expand Down
2 changes: 1 addition & 1 deletion unmarshaler.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import (
"io"

"github.com/klauspost/compress/gzip"
"github.com/nlnwa/gowarc/internal/countingreader"
"github.com/nlnwa/gowarc/v2/internal/countingreader"
)

// Unmarshaler is the interface implemented by types that can unmarshal a WARC record. A new instance of Unmarshaler is created by calling [NewUnmarshaler].
Expand Down
6 changes: 3 additions & 3 deletions warcfile.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ import (
"time"

"github.com/klauspost/compress/gzip"
"github.com/nlnwa/gowarc/internal"
"github.com/nlnwa/gowarc/internal/countingreader"
"github.com/nlnwa/gowarc/internal/timestamp"
"github.com/nlnwa/gowarc/v2/internal"
"github.com/nlnwa/gowarc/v2/internal/countingreader"
"github.com/nlnwa/gowarc/v2/internal/timestamp"
"github.com/prometheus/prometheus/tsdb/fileutil"
)

Expand Down

0 comments on commit 2cff962

Please sign in to comment.