New Upstream Release - golang-github-ruudk-golang-pdf417

Ready changes

Summary

Merged new upstream version: 0.0~git20201230.a7e3863+ds (was: 0.0~git20181029.1af4ab5).

Resulting package

Built on 2023-01-11T02:24 (took 4m10s)

The resulting binary packages can be installed (if you have the apt repository enabled) by running one of:

apt install -t fresh-releases golang-github-ruudk-golang-pdf417-dev

Lintian Result

Diff

diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml
new file mode 100644
index 0000000..52f5136
--- /dev/null
+++ b/.github/workflows/ci.yaml
@@ -0,0 +1,27 @@
+name: CI
+
+on:
+  push:
+    branches: [ master ]
+  pull_request:
+    branches: [ master ]
+
+jobs:
+  tests:
+    name: Tests
+    runs-on: ubuntu-20.04
+    steps:
+      - name: Set up Go 1.x
+        uses: actions/setup-go@v2
+        with:
+          go-version: ^1.15
+      - name: Check out code into the Go module directory
+        uses: actions/checkout@v2
+      - name: golangci-lint
+        uses: reviewdog/action-golangci-lint@v1
+        with:
+          fail_on_error: true
+          reporter: github-check
+          filter_mode: nofilter
+      - name: Test
+        run: go test $(go list ./...)
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index 17f1ba5..0000000
--- a/.travis.yml
+++ /dev/null
@@ -1,4 +0,0 @@
-language: go
-
-go:
-  - 1.11
diff --git a/README.md b/README.md
index 29bc8f4..4a1618c 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
 # PDF417 barcodes in Golang
 
-[![Build Status](https://travis-ci.org/ruudk/golang-pdf417.svg?branch=master)](https://travis-ci.org/ruudk/golang-pdf417)
+![CI](https://github.com/ruudk/golang-pdf417/workflows/CI/badge.svg)
 
 This is a port of https://github.com/ihabunek/pdf417-php
 
@@ -11,4 +11,3 @@ I only needed a way to draw PDF417 barcodes onto a [FPDF](https://github.com/jun
 See example: [examples/fpdf.go](examples/fpdf.go)
 
 If you want to export the barcode to an image, you have to create something that puts the PixelGrid onto the image. If you find a way, please submit a PR :)
-
diff --git a/debian/changelog b/debian/changelog
index 1e75ca5..85db1af 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+golang-github-ruudk-golang-pdf417 (0.0~git20201230.a7e3863+ds-1) UNRELEASED; urgency=low
+
+  * New upstream snapshot.
+
+ -- Debian Janitor <janitor@jelmer.uk>  Wed, 11 Jan 2023 02:20:57 -0000
+
 golang-github-ruudk-golang-pdf417 (0.0~git20181029.1af4ab5-2) unstable; urgency=low
 
   [ Debian Janitor ]
diff --git a/examples/fpdf.go b/examples/fpdf.go
index 430bd72..e0042ee 100644
--- a/examples/fpdf.go
+++ b/examples/fpdf.go
@@ -1,9 +1,10 @@
 package main
 
 import (
-	"github.com/jung-kurt/gofpdf"
-	"github.com/jung-kurt/gofpdf/contrib/barcode"
 	"fmt"
+
+	"github.com/phpdave11/gofpdf"
+	"github.com/phpdave11/gofpdf/contrib/barcode"
 )
 
 func main() {
diff --git a/go.mod b/go.mod
index 6fe8fdf..60b304e 100644
--- a/go.mod
+++ b/go.mod
@@ -1,9 +1,9 @@
 module github.com/ruudk/golang-pdf417
 
+go 1.15
+
 require (
 	github.com/boombuler/barcode v1.0.0
-	github.com/davecgh/go-spew v1.1.0 // indirect
-	github.com/jung-kurt/gofpdf v1.0.0
-	github.com/pmezard/go-difflib v1.0.0 // indirect
+	github.com/phpdave11/gofpdf v1.4.2
 	github.com/stretchr/testify v1.2.2
 )
diff --git a/go.sum b/go.sum
index 518eae8..9e03df6 100644
--- a/go.sum
+++ b/go.sum
@@ -1,10 +1,39 @@
 github.com/boombuler/barcode v1.0.0 h1:s1TvRnXwL2xJRaccrdcBQMZxq6X7DvsMogtmJeHDdrc=
 github.com/boombuler/barcode v1.0.0/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8=
+github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
 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/jung-kurt/gofpdf v1.0.0 h1:EroSdlP9BOoL5ssLYf3uLJXhCQMMM2fFxCJDKA3RhnA=
 github.com/jung-kurt/gofpdf v1.0.0/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes=
+github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI=
+github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
+github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
+github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE=
+github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
+github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
+github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
+github.com/phpdave11/gofpdf v1.4.2 h1:KPKiIbfwbvC/wOncwhrpRdXVj2CZTCFlw4wnoyjtHfQ=
+github.com/phpdave11/gofpdf v1.4.2/go.mod h1:zpO6xFn9yxo3YLyMvW8HcKWVdbNqgIfOOp2dXMnm1mY=
+github.com/phpdave11/gofpdi v1.0.12/go.mod h1:vBmVV0Do6hSBHC8uKUQ71JGW+ZGQq74llk/7bXwjDoI=
+github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
+github.com/pkg/errors v0.9.1/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/ruudk/golang-pdf417 v0.0.0-20181029194003-1af4ab5afa58/go.mod h1:6lfFZQK844Gfx8o5WFuvpxWRwnSoipWe/p622j1v06w=
+github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
 github.com/stretchr/testify v1.2.2 h1:bSDNvY7ZPG5RlJ8otE/7V6gMiyenm9RtJ7IUVIAoJ1w=
 github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
+github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0=
+github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
+golang.org/x/image v0.0.0-20190910094157-69e4b8554b2a/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
+gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
+gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
+gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo=
+gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
+gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776 h1:tQIYjPdBoyREyB9XMu+nnTclpTYkz2zFM+lzLJFO4gQ=
+gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
diff --git a/pdf417.go b/pdf417.go
index 24e4375..b7c657b 100644
--- a/pdf417.go
+++ b/pdf417.go
@@ -36,7 +36,7 @@ type Barcode struct {
 }
 
 func (c *Barcode) Metadata() barcode.Metadata {
-	return barcode.Metadata{"Pdf417", 2}
+	return barcode.Metadata{CodeKind: "Pdf417", Dimensions: 2}
 }
 
 func (c *Barcode) Content() string {
@@ -60,7 +60,7 @@ func (c *Barcode) Bounds() image.Rectangle {
 func (c *Barcode) At(x, y int) color.Color {
 	grid := c.PixelGrid()
 
-	if grid[y] != nil && grid[y][x] == true {
+	if grid[y] != nil && grid[y][x] {
 		return color.Black
 	}
 
diff --git a/text_encoder.go b/text_encoder.go
index 2ac9791..823c8e2 100644
--- a/text_encoder.go
+++ b/text_encoder.go
@@ -157,7 +157,7 @@ func encodeinterim(encoder TextEncoder, data string) []int {
 	for i := 0; i < len(data); i++ {
 		char := string(data[i])
 
-		if (existsInSubmode(encoder, char, submode) == false) {
+		if !existsInSubmode(encoder, char, submode) {
 			prevSubmode := submode
 
 			submode = getSubmode(encoder, char)

Debdiff

File lists identical (after any substitutions)

No differences were encountered in the control files

More details

Full run details