bmap/tool/bmap.go

28 lines
612 B
Go

package main
import "dev.justinjudd.org/justin/bmap"
const imageInputFilename = "/tmp/file.img"
const GZCompressedImageInputFilename = "/tmp/file.gz"
const bmapOutputFilename = "/tmp/test.bmap"
const imageOutputFilename = "/tmp/test.img"
func main() {
/*
b := bmap.NewBMap(imageInputFilename)
b.Write("/tmp/test.bmap")
*/
b, err := bmap.Load(bmapOutputFilename)
if err != nil {
println(err.Error())
}
//fmt.Printf("%#v\n", b)
//err = b.Copy(imageInputFilename, imageOutputFilename)
err = b.Copy(GZCompressedImageInputFilename, imageOutputFilename)
if err != nil {
println(err.Error())
}
}