I'm trying to build a docker container in windows 7 (Docker tool box with oracle VM) by running a shell script in git bash, and the script has the command with rsync like shown below:
rsync -a --exclude='*/node_modules' $PROJECT_PATH/project_name/src/ ./project_name/src
and the value for $PROJECT_PATH=/c/Users/yajnesh_rai/git
This is what I see in console:
ssh: Could not resolve hostname c: Name or service not known
rsync: connection unexpectedly closed (0 bytes received so far) [Receiver]
rsync error: error in rsync protocol data stream (code 12) at io.c(226) [Receiver=3.1.2]
Some online documentation says to use forward slashes for path without drive name, and I tried this way
$PROJECT_PATH=\\Users\\yajnesh_rai\\git
This makes rsync work, but fails to copy file, like shown below:
\Users\yajnesh_rai\git/project_name/src/folder_name/file_name: warning: directory does not exist.
I installed rsync on windows by following steps mentioned in this post: https://blog.tiger-workshop.com/add-rsync-to-git-bash-for-windows/
Any help to tackle the issue is appreciated!! Thanks in advance