Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
syscall: missing syscall.Winsize for both linux and darwin #3316
Just a simple complaint. Since linux's syscall package has Termios struct, is there a reason why it doesn't exist on darwin as well (or other OSes with similar terminal mechanics)? Another issue is ioctl's TIOCGWINSZ which uses 'struct winsize', I was thinking if Termios struct is defined, why can't we define Winsize as well?
In the mean time, maintaining your own syscall-type package is quite easy with a script like this: #!/bin/bash set -xe GOARCH=386 go tool cgo -godefs types_linux.go |gofmt -s >ztypes_linux_386.go GOARCH=amd64 go tool cgo -godefs types_linux.go |gofmt -s >ztypes_linux_amd64.go See types_linux.go in the current syscall package for the rest of the idea.