air-verse / air

☁️ Live reload for Go apps
GNU General Public License v3.0
16.35k stars 771 forks source link

Fix color output on Windows #551

Open 8LWXpg opened 3 months ago

8LWXpg commented 3 months ago

Fix #128

I simply compare util_windows.go with util_unix.go, and setting c.Stdout, c.Stderr seems to have resolve this issue.

Screenshot

image

8LWXpg commented 3 months ago

A question for this code: Returning stdout and stderr then io.Copy seems redundant, since setting c.Stdout = os.Stdout and c.Stderr = os.Stderr basically does the same thing. Is there reason for this?