prevent bash process substitution error in cygwin#1650
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1650 +/- ##
=========================================
+ Coverage 56.07% 56.17% +0.1%
=========================================
Files 306 300 -6
Lines 20950 20640 -310
=========================================
- Hits 11747 11594 -153
+ Misses 8354 8210 -144
+ Partials 849 836 -13 |
|
Thanks for reporting. I have to take a closer look and hope to get back on you on monday. |
|
I cannot reproduce the problem. $ cat < <(echo Hugo)
HugoI tested with current cygwin 32-bit on Windows 7 and current cygwin 64-bit on Windows 10. |
albers
left a comment
There was a problem hiding this comment.
As your improved version also works for other operating systems, there's no need to branch here by OS.
Please change line 596 to always use command substitution.
0c4eb00 to
40ea5d6
Compare
|
@albers looks like the PR was updated |
| __docker_fetch_info() { | ||
| if [ -z "$info_fetched" ] ; then | ||
| read -r client_experimental server_experimental server_os < <(__docker_q version -f '{{.Client.Experimental}} {{.Server.Experimental}} {{.Server.Os}}') | ||
| # prevent bash substitution error in cygwin : /dev/fd/62 : No such file or directory error |
There was a problem hiding this comment.
I don't think we need this comment here. It will not be useful for readers once this PR is merged.
It is sufficient to mention the rationale behind this change in the commit message.
Signed-off-by: Matteo Orefice <matteo.orefice@bites4bits.software>
40ea5d6 to
0b49495
Compare
|
LGTM, thanks very much for your contribution. |
|
Thanks to the docker community which allows us better devops, I hope to contribute many more time asap |
|
Thanks! That's really appreciated |
Signed-off-by: Matteo Orefice matteo.orefice@bites4bits.software
fixes
/dev/fd/62 : No such file or directoryrunning clidockerbash completion in cygwinI founded cygwin bash cannot handle bash Process Substitution in
__docker_fetch_info()function- What I did
Added code to run in cygwin doesn't use Process Substitution and fallbacks to here string
- How I did it
could be rewritten as here string avoiding a pipe creation :
- How to verify it
dockerand press multiple to trigger completion/dev/fd/62 : No such file or directory- Description for the changelog
Prevent bash docker/cli completion error
/dev/fd/62 : No such file or directoryfrom occurring under cygwin