bingo

command module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 3, 2018 License: MIT Imports: 9 Imported by: 0

README

bingo

Bingo is a command-line utility making Go source files from the given binary. It is like go.rice, go-bindata, go-embed and other awesome tools.

But the bingo is much more simple. It just gets a single file and makes a single .go source with a single []byte variable. That is all. No additional functionality.

For example, the echo 'Lorem ipsum' | bingo -var Lorem will produce:

// Code generated by bingo. DO NOT EDIT.
package main

var Lorem = []byte("\x4c\x6f\x72\x65\x6d\x20\x69\x70\x73\x75\x6d\x0a")

Bingo can be used with go generate as:

//go:generate bingo -in mybinfile.bin -out mybinfile.go -pkg mypack -var BinData

CLI flags of bingo

Usage of bingo:
  -help
        Show help
  -in string
        Input file or stdin if empty
  -out string
        Output file or stdout if empty
  -pkg string
        Package name (default "main")
  -var string
        Variable name (default "foo")

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL