Skip to content

Commit ea161b6

Browse files
committed
Removed internal/Version.go
1 parent 3783c71 commit ea161b6

15 files changed

Lines changed: 82 additions & 26 deletions

File tree

bin/clean.sh

100644100755
File mode changed.

cmd/asciify/asciify.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,13 @@ import (
88
"golang.org/x/text/encoding/charmap"
99
)
1010

11+
var (
12+
BUILDER = "unknown"
13+
COMMIT = "(local)"
14+
LASTMOD = "(local)"
15+
VERSION = "internal"
16+
)
17+
1118
func main() {
1219

1320
input, err := os.ReadFile("/dev/stdin")

cmd/asciitable/asciitable.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ import (
1010
"golang.org/x/text/encoding/charmap"
1111
)
1212

13+
var (
14+
BUILDER = "unknown"
15+
COMMIT = "(local)"
16+
LASTMOD = "(local)"
17+
VERSION = "internal"
18+
)
19+
1320
var asciiMap = map[int]string{
1421
0x00: "NUL", 0x01: "SOH", 0x02: "STX", 0x03: "ETX",
1522
0x04: "EOT", 0x05: "ENQ", 0x06: "ACK", 0x07: "BEL",

cmd/bytecount/bytecount.go

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import (
66
"io"
77
"os"
88

9-
"github.com/FileFormatInfo/fftools/internal"
109
"github.com/olekukonko/tablewriter"
1110
"github.com/olekukonko/tablewriter/renderer"
1211
"github.com/olekukonko/tablewriter/tw"
@@ -15,6 +14,13 @@ import (
1514
"golang.org/x/text/message"
1615
)
1716

17+
var (
18+
BUILDER = "unknown"
19+
COMMIT = "(local)"
20+
LASTMOD = "(local)"
21+
VERSION = "internal"
22+
)
23+
1824
func outputPretty(out io.Writer, counts map[byte]int) {
1925

2026
// LATER: use https://github.com/jeandeaual/go-locale to determine locale
@@ -92,7 +98,7 @@ func main() {
9298
pflag.Parse()
9399

94100
if *version {
95-
internal.PrintVersion("bytecount")
101+
fmt.Fprintf(os.Stdout, "bytecount version %s (built by %s on %s, commit %s)\n", VERSION, BUILDER, LASTMOD, COMMIT)
96102
return
97103
}
98104

cmd/certinfo/certinfo.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,13 @@ import (
1111
"strings"
1212
)
1313

14+
var (
15+
BUILDER = "unknown"
16+
COMMIT = "(local)"
17+
LASTMOD = "(local)"
18+
VERSION = "internal"
19+
)
20+
1421
func usage() {
1522
fmt.Fprintf(os.Stderr, "Usage: certinfo url|file\n")
1623
fmt.Fprintf(os.Stderr, "Examples:\n")

cmd/ghash/ghash.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,13 @@ import (
2424
"github.com/spf13/pflag"
2525
)
2626

27+
var (
28+
BUILDER = "unknown"
29+
COMMIT = "(local)"
30+
LASTMOD = "(local)"
31+
VERSION = "internal"
32+
)
33+
2734
// struct with name and hash
2835
type Hasher struct {
2936
name string

cmd/hexdumpc/hexdumpc.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,13 @@ import (
99
"github.com/spf13/pflag"
1010
)
1111

12+
var (
13+
BUILDER = "unknown"
14+
COMMIT = "(local)"
15+
LASTMOD = "(local)"
16+
VERSION = "internal"
17+
)
18+
1219
func hexdump(fileName string, offset, length int64, w io.Writer) error {
1320

1421
// Open the file

cmd/spinner/spinner.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,13 @@ import (
77
"github.com/FileFormatInfo/fftools/internal"
88
)
99

10+
var (
11+
BUILDER = "unknown"
12+
COMMIT = "(local)"
13+
LASTMOD = "(local)"
14+
VERSION = "internal"
15+
)
16+
1017
var (
1118
solid = [...]string{"\u2022", "\u23FA", "\u25CF", "\u2B24"}
1219
hollow = [...]string{"\u25E6", "\uFFEE", "\u25CB", "\u25EF", "\u2B58"}

cmd/unhexdump/unhexdump.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ import (
1010
"strings"
1111
)
1212

13+
var (
14+
BUILDER = "unknown"
15+
COMMIT = "(local)"
16+
LASTMOD = "(local)"
17+
VERSION = "internal"
18+
)
19+
1320
var linePattern = regexp.MustCompile(`^.*[|]([ 0-9a-fA-F]+)[|].*$`)
1421

1522
func parseLine(line string, dst *os.File) error {

cmd/unicount/unicount.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,13 @@ import (
1212
"golang.org/x/text/unicode/runenames"
1313
)
1414

15+
var (
16+
BUILDER = "unknown"
17+
COMMIT = "(local)"
18+
LASTMOD = "(local)"
19+
VERSION = "internal"
20+
)
21+
1522
func main() {
1623

1724
var control = pflag.Bool("control", false, "Include control characters")

0 commit comments

Comments
 (0)