Closed viney closed 4 years ago
package main
import ( "os"
"github.com/sbinet/go-python"
)
func init() { if err := python.Initialize(); err != nil { panic(err) } }
func main(){ rc:=python.Py_Main(os.Args) os.Exit(rc) }
default open python2.7 in ubuntu16.04
sbinet/go-python only supports CPython2.
sbinet/go-python
for CPython3, you may want to look at: https://github.com/DataDog/go-python3
package main
import ( "os"
)
func init() { if err := python.Initialize(); err != nil { panic(err) } }
func main(){ rc:=python.Py_Main(os.Args) os.Exit(rc) }
default open python2.7 in ubuntu16.04