wtfutil / wtf

The personal information dashboard for your terminal
http://wtfutil.com
Mozilla Public License 2.0
15.71k stars 799 forks source link

Build failed in Windows #1574

Open ibrahim-13 opened 1 year ago

ibrahim-13 commented 1 year ago

What's broken?

cmdrunner Module uses syscall.SIGWINCH which is undefined for Windows-

github.com/wtfutil/wtf/modules/cmdrunner
# github.com/wtfutil/wtf/modules/cmdrunner
modules\cmdrunner\widget.go:161:28: undefined: syscall.SIGWINCH
modules\cmdrunner\widget.go:169:16: undefined: syscall.SIGWINCH

Reference commit which triggered this behavior: commit/c7ac2be510d28d572fb10c6b9ccc2319a85c49fc

Additional Information

From what I've found googling, syscall.SIGWINCH is Unix/Linux specific and has no equivalent replacement in Windows. For now, build directive can be added to compile on Windows and panic on runtime when/if the module is used. Here is an example: https://github.com/cloudfoundry/cli/tree/v7.1.0/util/clissh/sigwinch About SIGWINCH: GNU Manual

Here is the commit that I'v made on my repository to make it work: commit/5c16134f65ae41d7968038ec0463137ddde56178 If this is acceptable, I can create a pull request for this commit only.

stale[bot] commented 11 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.