jwgrenning / tddec-code

Book code for Test-Driven Development for Embedded C
255 stars 89 forks source link

different instructions are needed to set up Docker in Windows #12

Open keith-at-spacee opened 5 years ago

keith-at-spacee commented 5 years ago

When running from a Windows cmd.exe command line, slightly modified settings are needed to set the environment variables and use these when kicking off Docker. I found the following to work in Windows. It assumes you have pulled the sources into folder C:\Users\YourName\tddec-code.

set PWD=/c/Users/YourName set MOUNT_DIR=%PWD%:/usr/src set WORKING_DIR=/usr/src/tddec-code set CPPUTEST_HOME=%WORKING_DIR%/cpputest

Check things out with a bash invocation as follows: C:\Users\YourName>docker run -it -v %MOUNT_DIR% -w %WORKING_DIR% -e CPPUTEST_HOME gcc:7 /bin/bash

then do the usual things like make etc.

keith-at-spacee commented 5 years ago

a proposal is in PR 13 at https://github.com/jwgrenning/tddec-code/pull/13