help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

help on simple makefile


From: address@hidden
Subject: help on simple makefile
Date: Wed, 5 Apr 2017 22:39:40 +0200 (CEST)

Hi there!! i have  some files .txt and I want to trasform all using a python 
script to another output on new directory:

SCRIPT=~/Desktop/python_script.py
RDIR=.
RFILES:=$(wildcard $(RDIR)/*.txt)
.PHONY: clean all


prepare: 
    mkdir RESHAPE2 ;\
    for d in $(RFILES);\
        do \
        echo $(SCRIPT) -i  $$d -o RESHAPE2/%.xls  ;done

mitico: $(RFILES)
    @ echo $^|sed 's/.txt/.xls/g'
listfiles:
    (ls -ltr RESHAPE2/)

    
clean:
    rm -rf RESHAPE2/*.xls



Could you please help me on translate on working  example.

What I want to obtain is  execute the python script on file present on my 
folder and output on RESHAPE2.
thanks in advance for any help



reply via email to

[Prev in Thread] Current Thread [Next in Thread]