Skip to content

Latest commit

 

History

History
21 lines (18 loc) · 263 Bytes

README.md

File metadata and controls

21 lines (18 loc) · 263 Bytes

bencode

bencode implementation in go

example

Encode a map[string]interface{}

e := New(map[string]interface{}{
		"spam": []interface{}{
			"a",
			"b",
		},
	})
e.Encode()

Decode a dictionary

d := New([]byte("d4:spaml1:a1:bee"))
d.Decode()