I have the makefile
.PHONY: start-generate
start-generate:
source activate myenv
mkdir "data_channels_`date +%Y%m%d_%H%M%S`"
python main/datageneration.py ./"data_channels_`date +%Y%m%d_%H%M%S`" 3
but when I run it I get
$ make start-generate
source activate myenv
make: source: Command not found
make: *** [start-generate] Error 127
although I am able to run source activate myenv
outside make.
If I alternatively try
start-generate:
( \
source activate myenv; \
mkdir "data_channels_`date +%Y%m%d_%H%M%S`"; \
python main/datageneration.py ./"data_channels_`date +%Y%m%d_%H%M%S`" 3; \
)
I get the error
/bin/sh: 2: source: not found
Traceback (most recent call last):
File "main/datageneration.py", line 1, in <module>
import pandas as pd
ImportError: No module named pandas
make: *** [start-generate] Fehler 1
The error with pandas is obviously, because the source-command did not work. And regarding that there is the message /bin/sh: 2: source: not found
. Maybe the issue is that I need /bin/bash
instead of /bin/sh
? If so, how do I get it?
What is the issue here?