Files
old-krovovi-kalkulator/watch.sh
2017-11-21 17:11:29 +01:00

17 lines
341 B
Bash
Executable File

#!/bin/bash
# Watches for changes in the files and passes to docker
# ignores the folders: node_modules, .git
cwd=$(pwd)
fswatch -0 -e node_modules -e .git -e env . | while read -d "" absPath
do
shortPath=""
shortPath=${absPath/$cwd/$shortPath}
echo "${shortPath}"
docker cp $absPath helix:project${shortPath}
done