Running a command if any files are copied.
Michael Ellis <[email protected]> Fri, 16 Sep 2005 10:04:46 -0500
| Newsgroups | gmane.comp.tools.aap.user |
|---|---|
| Message-ID | <[email protected]> |
Just discovered Aap yesterday. Very impressive! Question: What's best way to copy one or more changed files to a local target and if (and only if) any files were copied, run a system command? For example, here's a snippet from a main.aap I'm creating to replace a fairly complicated makefile. #install the udev rules :sys cp acceleron.rules /etc/udev/rules.d/ :sys /sbin/udevstart This always copies the rules file and always runs udevstart. I'd like to copy the rules only when the file changes and only run udevstart when a file was copied. I'd also like to generalize it to handle more than one .rules file. After going through the manual, this seems like a publish rather than a compile situation, but I couldn't figure out how to hook the call to udevstart to the publish action. Thanks, Mike Ellis -- Michael F. Ellis Managing Partner Ellis & Grant, Inc. Make Better Decisions with PeerTool! http://www.peertools.com ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php