Working From Raw Source Data From A Filepath Containing Spaces Using Make And Makefiles
I have a repository that uses python scripts and a Makefile. I want to have a setup procedure that allows them to easily set up an environment and copy in the necessary data files
Solution 1:
One fix would be:
local/inputs1.csv :
python copyfile.py "V:\\Server Path\\With Spaces\\Inputs 1.csv" $@
local/inputs2.csv :
python copyfile.py "V:\\Server Path\\With Spaces\\Inputs 2.csv" $@
output.csv : combine_data.R | local/inputs1.csv local/inputs2.csv
Rscript $^ $| $@
Note that local/inputs1.csv
and local/inputs2.csv
are made order-only prerequisites, so that they are only made when they don't exist (unless you'd like to copy them every time the makefile is run). Automatic variable $|
refers to order-only prerequisites, they aren't included in $^
.
Post a Comment for "Working From Raw Source Data From A Filepath Containing Spaces Using Make And Makefiles"