Move edit functions to edit.go
Add LICENSE header to edit.go