Josh Cronemeyer wrote:

I have heard of people using make for other things besides compiling
software.  I have an application that I would like to try to use make
on, but not having any experience with make I am not sure if it is
feasable.  Here is my idea.

I have my home page (actually about 400 pages worth) on my ISP's unix
servers.  I make changes to the site on my local machine, and whenever I
make changes I run a perl script that removes the whole site and reloads
the whole site. This is slow! Often I change 20 to 30 pages at a time so
this is easier than uploading via ftp every page that i have changed.

I was thinking that since make can detect changes in files that it would
be able to identify which files were modified and then i would be able
to run my script on just those files. Much faster that way! Sure i could
write my perl script to do this too, but I was hoping to reuse existing
software and to learn about make.

could that work?
Something like this might do the job:

all : $(patsubst %,%.upped,$(wildcard *.html))

%.upped : %
        curl --netrc --upload-file $<  ftp://your.isp.here/path/$<
        touch $@

You may need to use e.g. VPATH to find all the .html files you want. You can, of course, easily add other extentions, if you want :)
HTH


rlc



_______________________________________________
Help-make mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to