You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[skip changelog] Make i18n:generate task Windows compatible (#1360)
For the sake of portability of tasks, Task uses `mvdan.cc/sh` to provide an command interpreter that is independent of
the environment. While one of the great strengths of Task, this produces unexpected results in some rare cases. This is
one of those cases. There is some unusual interaction between `mvdan.cc/sh`, Windows, and running the `rice embed-go`
command from the subshell created by the parentheses in this command:
```
$ task i18n:update
←[32mtask: [i18n:update] go run ./i18n/cmd/main.go catalog generate . > ./i18n/data/en.po
←[0m←[32mtask: [i18n:generate] git add -N ./i18n/data
←[0m←[32mtask: [i18n:generate] git diff --exit-code ./i18n/data &> /dev/null || (cd ./i18n && rice embed-go)
←[0merror reading package: go/build: go list github.com/arduino/arduino-cli/i18n: exec: "go": executable file not found in %PATH%
```
It is my belief that the sole purpose of these parentheses was to group the commands and that there is no need to run
these commands in a subshell. If so, the change to using braces to group the commands without the creation of a subshell
will have no functional effect on the commands, but will allow the task to run on Windows.
0 commit comments